-
-
Notifications
You must be signed in to change notification settings - Fork 26.2k
Closed
Labels
EasyWell-defined and straightforward way to resolveWell-defined and straightforward way to resolvegood first issueEasy with clear instructions to resolveEasy with clear instructions to resolve
Description
test_numeric_stability
can be parametrize with pytest:
scikit-learn/sklearn/preprocessing/tests/test_discretization.py
Lines 138 to 146 in 3ab22f9
def test_numeric_stability(): | |
X_init = np.array([2., 4., 6., 8., 10.]).reshape(-1, 1) | |
Xt_expected = np.array([0, 0, 1, 1, 1]).reshape(-1, 1) | |
# Test up to discretizing nano units | |
for i in range(1, 9): | |
X = X_init / 10**i | |
Xt = KBinsDiscretizer(n_bins=2, encode='ordinal').fit_transform(X) | |
assert_array_equal(Xt_expected, Xt) |
(Using this as an example of how to contribute to scikit-learn for a talk)
Metadata
Metadata
Assignees
Labels
EasyWell-defined and straightforward way to resolveWell-defined and straightforward way to resolvegood first issueEasy with clear instructions to resolveEasy with clear instructions to resolve