Skip to content

Commit 4040d42

Browse files
veneamueller
authored andcommitted
Make randomized_svd flipped by default
1 parent 160648d commit 4040d42

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sklearn/utils/extmath.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ def randomized_range_finder(A, size, n_iter, random_state=None,
132132

133133

134134
def randomized_svd(M, n_components, n_oversamples=10, n_iter=0,
135-
transpose='auto', flip_sign=False, random_state=0,
135+
transpose='auto', flip_sign=True, random_state=0,
136136
n_iterations=None):
137137
"""Computes a truncated randomized SVD
138138
@@ -160,7 +160,7 @@ def randomized_svd(M, n_components, n_oversamples=10, n_iter=0,
160160
implementation of randomized SVD tend to be a little faster in that
161161
case).
162162
163-
flip_sign: boolean, (False by default)
163+
flip_sign: boolean, (True by default)
164164
The output of a singular value decomposition is only unique up to a
165165
permutation of the signs of the singular vectors. If `flip_sign` is
166166
set to `True`, the sign ambiguity is resolved by making the largest

0 commit comments

Comments
 (0)