8000 modify common tests · scikit-learn/scikit-learn@bf459f4 · GitHub
[go: up one dir, main page]

Skip to content

Commit bf459f4

Browse files
committed
modify common tests
1 parent f71f6d6 commit bf459f4

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

sklearn/utils/estimator_checks.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -691,7 +691,11 @@ def check_fit_score_takes_y(name, Estimator):
691691
@ignore_warnings
692692
def check_estimators_dtypes(name, Estimator):
693693
rnd = np.random.RandomState(0)
694-
X_train_32 = 3 * rnd.uniform(1.0, 2.0, size=(20, 5)).astype(np.float32)
694+
if name in ["BoxCoxTransformer", "SpectralCoclustering",
695+
"SpectralBiclustering"]:
696+
X_train_32 = 3 * rnd.uniform(1., 2., size=(20, 5)).astype(np.float32)
697+
else:
698+
X_train_32 = 3 * rnd.uniform(size=(20, 5)).astype(np.float32)
695699
X_train_64 = X_train_32.astype(np.float64)
696700
X_train_int_64 = X_train_32.astype(np.int64)
697701
X_train_int_32 = X_train_32.astype(np.int32)

0 commit comments

Comments
 (0)
0