8000 Reduce precision requirements for float32 PCA (#12825) · scikit-learn/scikit-learn@57e058e · GitHub
[go: up one dir, main page]

8000 Skip to content

Commit 57e058e

Browse files
committed
Reduce precision requirements for float32 PCA (#12825)
Fixes #12823
1 parent a941c2e commit 57e058e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

sklearn/decomposition/tests/test_pca.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -723,8 +723,9 @@ def check_pca_float_dtype_preservation(svd_solver):
723723
assert pca_64.transform(X_64).dtype == np.float64
724724
assert pca_32.transform(X_32).dtype == np.float32
725725

726+
# decimal=5 fails on mac with scipy = 1.1.0
726727
assert_array_almost_equal(pca_64.components_, pca_32.components_,
727-
decimal=5)
728+
decimal=4)
728729

729730

730731
def check_pca_int_dtype_upcast_to_double(svd_solver):

0 commit comments

Comments
 (0)
0