question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

linear_assignment can now be imported from scipy

See original GitHub issue

sklearn.utils.linear_assignment_ can be replaced by scipy.optimize.linear_sum_assignment now that scipy >= 0.17 is required by scikit-learn.

The sklearn.utils.linear_assignment_ module should be deprecated to be removed in 0.23 (assuming this issue gets fixed before 0.21’s release).

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
yiakwycommented, Mar 10, 2020

@jnhansen @praths007 I am concerned that linear_sum_assignment is not equivalent to linear_assignment which later implements “maximum values” matching strategy not “complete matching” strategy, i.e. in tracking problem maybe an old landmark lost and a new detection coming in. We don’t have to make a complete assignment, just match as more as possible.

I also try to tell others that it is dangerous to use linear_sum_assignment because it implements complete matching, where in the most cases we don’t need.

Instead of using complete matching by KM algorithms, mini cut - max flow might be a good choice.

0reactions
thomasjpfancommented, Apr 17, 2019

Resolved in #13465

Read more comments on GitHub >

github_iconTop Results From Across the Web

No module named 'sklearn.utils.linear_assignment_'
from scipy.optimize import linear_sum_assignment as linear_assignment. then you can run the file and don't need to change the code.
Read more >
scipy.optimize.linear_sum_assignment — SciPy v1.9.3 Manual
An array of row indices and one of corresponding column indices giving the optimal assignment. The cost of the assignment can be computed...
Read more >
SciPy 1.4.0 Release Notes — SciPy v1.9.3 Manual
Documentation can now be built with runtests.py --doc ... will unconditionally refer to the NumPy version regardless of whether scipy.special is imported.
Read more >
SciPy 1.7.0 Release Notes — SciPy v1.9.3 Manual
Our development attention will now shift to bug-fix releases on the 1.7.x branch, and on adding ... #13236: MAINT: reorganize shared linear assignment...
Read more >
SciPy 1.6.0 Release Notes — SciPy v1.9.3 Manual
Our development attention will now shift to bug-fix releases on the 1.6.x branch, ... also known as the linear assignment problem, has been...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found