This is a fast version of LAP for numpy.

  
      
      github.com
  
  
    

cheind/py-lapsolver 160


  Fast linear assignment problem (LAP) solvers for Python based on c-extensions

  
  
    
    
  
  


transfer torch 2 numpy and come back!
enjoy it.