8000 Merge pull request #3593 from MechCoder/row_norms_doc_fix · scikit-learn/scikit-learn@d6bfe09 · GitHub
[go: up one dir, main page]

Skip to content

Commit d6bfe09

Browse files
committed
Merge pull request #3593 from MechCoder/row_norms_doc_fix
[MRG] DOC: Added np.sqrt since default is 'squared=False'
2 parents 796d67f + 9e58bcd commit d6bfe09

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
@@ -54,8 +54,8 @@ def squared_norm(x):
5454
def row_norms(X, squared=False):
5555
"""Row-wise (squared) Euclidean norm of X.
5656
57-
Equivalent to (X * X).sum(axis=1), but also supports CSR sparse matrices
58-
and does not create an X.shape-sized temporary.
57+
Equivalent to np.sqrt((X * X).sum(axis=1)), but also supports CSR sparse
58+
matrices and does not create an X.shape-sized temporary.
5959
6060
Performs no input validation.
6161
"""

0 commit comments

Comments
 (0)
0