Skip to content

Commit fa8fe85

Browse files
committed
update what's new + simplify test
1 parent 388df6b commit fa8fe85

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

doc/whats_new.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,9 @@ Bug fixes
348348
<https://github.com/scikit-learn/scikit-learn/issues/7194>`_). By `Caio
349349
Oliveira <https://github.com/caioaao>`_.
350350

351+
- Fix :class:`linear_model.ElasticNet` sparse decision function to match
352+
output with dense in the multioutput case.
353+
351354
API changes summary
352355
-------------------
353356

sklearn/linear_model/tests/test_sparse_coordinate_descent.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -285,10 +285,7 @@ def test_same_multiple_output_sparse_dense():
285285
predict_dense = l.predict(sample)
286286

287287
l_sp = ElasticNet(normalize=normalize)
288-
X_sp = sp.coo_matrix([[0, 1, 2, 3, 4],
289-
[0, 2, 5, 8, 11],
290-
[9, 10, 11, 12, 13],
291-
[10, 11, 12, 13, 14]])
288+
X_sp = sp.coo_matrix(X)
292289
ignore_warnings(l_sp.fit)(X_sp, y)
293290
sample_sparse = sp.coo_matrix(sample)
294291
predict_sparse = l_sp.predict(sample_sparse)

0 commit comments

Comments
 (0)