ELF          >            @       q          @ 8 	 @                                 P      P                                                                    @       @       @      9      9                   ]      m      m                               ]      m      m                               8      8      8      $       $              Ptd   PM      PM      PM      d       d              Qtd                                                  Rtd   ]      m      m      `      `                      GNU :
,ѭQ$ }       !               !                                                                                                                                                                    *                                           _                                                                  y                     ,                       U                      F   "                                         q                                                                                                                                                                                                 N                                                                                                                               9                          @      ;       __gmon_start__ _ITM_deregisterTMCloneTable _ITM_registerTMCloneTable __cxa_finalize PyArg_ParseTupleAndKeywords PyEval_SaveThread PyEval_RestoreThread Py_BuildValue _Py_Dealloc PyExc_ValueError PyErr_Format PyExc_TypeError PyErr_SetString PyInit__lsap PyImport_ImportModule PyObject_GetAttrString PyCapsule_Type PyCapsule_GetPointer PyModule_Create2 PyExc_ModuleNotFoundError PyErr_ExceptionMatches PyErr_Print PyExc_ImportError PyErr_Clear PyExc_RuntimeError _ZdlPvm memmove _Znwm memset _ZSt20__throw_length_errorPKc memcpy _Unwind_Resume __gxx_personality_v0 libstdc++.so.6 libgcc_s.so.1 libc.so.6 GCC_3.0 GLIBC_2.14 GLIBC_2.2.5 CXXABI_1.3 CXXABI_1.3.9 GLIBCXX_3.4                                             B         P&y   Z        P     0      b     ui	   m        3         ӯk   y     yѯ        t)         m             `      m                    m             m      p             @      p             @      q             @      q             C       q             `q      `q             @      hq             p      xq             C      o                    o                    o                    o                    o                    o         	           o                    o                    o                    o                    q                     p                    p                    p                    p         
            p                    (p                    0p                    8p                    @p                    Hp                    Pp                    Xp                    `p                    hp                    pp                    xp                    p                    p                    p                    p                    p                    p                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     HH_  HtH     5_  %_  @ %_  h    %_  h   %_  h   %_  h   %_  h   %_  h   %_  h   %_  h   p%_  h   `%_  h	   P%z_  h
   @%r_  h   0%j_  h    %b_  h   %Z_  h    %R_  h   %J_  h   %B_  h   %:_  h   %2_  h   %*_  h   %"_  h                                                   H=/  dH=;  XHt$`HLhH$P  K  H$   >  Ht$`LAH$   H$   H)HucHt$`LHt$`HHt$`LH$   H|$H$   HD$HH)HtHHHH=@:  Hf.     @ H=^  H^  H9tH\  Ht	        H=^  H5^  H)HH?HHHtH\  HtfD      =}^   u+UH=\   HtH=nZ  IdU^  ]     w    AWH1HAVH=]  Hv,  AUATUSHHLL$,LD$0HD$0    D$,      H]     H(  h  H|$0E11HA  1HH  P  LpM  H@ Hl$8      HL LhLM9INHE1E1HD$@Hb]  Hxj j j   IH H  H;]  HE1E1H      Hxj j j   HH H4  MGLHLD$LL$1LL$LHD$D$,LLLD$E  H|$AA  AD  HLH= +  1HxHHx  ff.     IxHI  HU x^HHU uTHHD$HD$HH[]A\A]A^A_f     H	Z  H5J+  H81Hx	HHt1HH[]A\A]A^A_    H(fD  HxHH  IxHIuLfHy    HY  H5)  H8
Hnrf.     HIY  H5*  H8Hx	HHt
1 HxIxHI   H1HHD$GIHD$~fHX  H5A)  H8ZHy1L@ H Iy@ LHD$HD$-f     L_ UH=(  SHHH   H5)  HsHHE xHHE    H   HX  H9C  1HHHY  x	HHtwH  HY          1  HY    @     H  H=X  [] HQ HHiY  u@ HiW  H8u-H)W  H5"+  H8H1[]f     H='  oHH봐H)W  H5(  H8zHxHHuH"   H5(  HV  H81_]HV  H5,*  H8$BHV  H5(  1H:    HV  H5)  H8HyV  H5'  H8D  AWAVAUATUSH  H|$LD$xL$   H   IH   II׉LH9
  
  HD$H    IIHǄ$       HǄ$       M~h?3  1D  Af.wf.{>AHD$HHtH$   HE1HĈ  D[]A\A]A^A_@ HL9uLH<VJ    LT$ HLD$HL$H$   1HHHD$LD$LH<L$J    L$HH\$`L\$kHH1IKHSL$H     HH@L\$LT$ HD$XLHH|$(t0H1HLD$HL$LT$ LD$HL$HD$XLt$`L$   LD$0LL$HL   IH$   fHǄ$       )$   HHHھ   H$   HH$   gLH$   Ld   HHH\$`I<L$HǄ$       HǄ$(      IC?HǄ$0      HL\$H4    HǄ$8      HH$   HǄ$@      H$   L\$HH$H$   H0H1L\$PH$@  LǄ$(      HH    HH$   HLHǃ?HL$8H\$h\$ H$0  $8  RLD$0HǄ$P      HǄ$X      HǄ$`      I@?HǄ$h      HH4    HǄ$p      HH$   H$   LD$0HHD$H$P  H0H1Ǆ$X      H$p  LHH    HH$   HLHǃ?HL$@H\$p$   H$`  $h  mH|$`sH|$( H     HLD$0L\$PL$   t2HD$`H{1LT$PLD$0HPL\$(L\$(LD$0LT$PHD$X@   L$   E1H)H$   HHHHD$0D$ )HHH$   @ IU  L¿   fInHfHnHflfvHfoj.  flH fofofHff@H9uLHAtLH)HHH<$H9|$8  H$   1LD$PL\$(LL$ H|$h LL$ L\$(LD$PtH$   H|$8HH!7H|$H9|$@  H$   1LD$PL\$(LL$ H|$p LL$ L\$(LD$Pt&$   @   H|$@)HHHHH!HD$XH9ttH$     HL$0\-  HHfHHT tHEE H9t     H @H9uHD$0tHHD H=-  H8LL$ LLfL\$(-,  A   fHHF?HH$HIH?H:HHH?H)yH@HLHH	H(  HD$Mf(1LI$      f.z	uI<tGHH9tNHJAHL 	X\A\f/vIt f(f/vIHf(H9uf.z   NHIMIuHIHHJ?Ht$HIHH4HH?H:Hʃ?H)Hx/LHH	HHIH   f(LD  H@LHH	VAHt$`HmH$   H|$[H$   H<$JHt$`L=H$   HtH$   H) H\$`LHHHHLH$   H|$LL$ L\$(HPLT$H$HD$ 1H$   LD$(   CMXCff.     HIHIL#tI9tHf(\D AXAHL9uHD$ LD$(Ht$ 1Ht$   ff.     ff.     ff.     f     HIHIL#tf(\L A\AHL9uHt$ D  IT HHIHH9L9uIM9L$   L9T$7  I  HL$xH$   HAH)HHAH9R  HFH9E  LA   fo)  1HfInHflfofoHH9uLHAtH|$xHH$   HHE1hfH|$p B$   @   H|$@)HHHH!H|$h H$   H|$8HH!LH<J    L$HgL$HxHD$HIH     LHH$      H1L)HPIL$H$   H$   L9T$#  H|$   M  LL$J<    Ht$HE1IJ    LHH)ff.     ff.     f HHI9uIHIM9uLD$M@  L|$H"1HDL9T$  H|$   HǄ$      MELD$M@tHD$H fW&  I 1H|$xHH$   HHHI9H|$HHLL$L$L\$MLH\$H&  HHHfHf HfW@H9uLHAH\$HH fWG&   H$   H$   9  H$   H$  H9tmL$   LL$xH)1L$   HI4I4IHH9uH$  H)ILD$M@QHHǄ$      LD$M@$qf.     AL\$MHǄ$      ADIHHHHHHHp H     SHH?Ht1Hs H)H    C    HC    C    HC     [ÐH9   AWAVIAUATIUSH_HH9t~I׽   *HL)H~|HLH)HHM,$I9tJL+II$J4H>H;<|HSHCH;<}AHPHHPHLL9|L/HI9uH[]A\A]A^A_D  uH뎐HL/f.     f.     f.     f.     f.     D  HBAWIAVAUIATIAUI?HSIILl$L9:  MIfN<HI9  IIBH HHJHHL0L;O,O9,N4I9H|$ t}LRLH?LHH9~RMK5ff.     ff.     HQL HH?HHHH9}dHLHHMK9|L[]A\A]A^A_    HHH?HHH9iHTHLLHR    LL[]A\A]A^A_    H|$ H$    H|$ HsHHH?HHH9YH냐HH)H=     AWIAVIHAUIIATIUHoSHHM&  MLIL$IMAo$HMuI<K4fofH~OfH9X  L9v  L9T  A$IuILI9}fHff.     HIHI9|I;}JHGfD  H0HHI9I9s;I6IFHwHI$IVII9|II;|fHI9r    HLLLLL)H=   }   MIHIMHhHIILHLHuLIL)H~2fI$LIM IL)1LIIEHHHH[]A\A]A^A_L9L9}M4$HIUI$IT$M$II$IT$IuHAWAVAUATUSHH^H+IIH9  fHG    HM  HIHHE IL`HMHL$H     ItLHS1xLd$LeM9j  LLL)HHHHH  Hʻ   fo  fHfnHfp Lff.     ff.     fD  fofofH fffofbfjX@H9uHHIT   HcH
HJI9   LL)HH  HHH LLL`H      I   LLHI9t]IfD  LHSHCJ4H<H9>   ff.     f     HPHHPHLL9|HLI9uHH[]A\A]A^A_f.     HG    ڍHHcHJHJI9HHBLHL)HH	LHLLbLLLs    HHLI9TL1H=  *  HH                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           O|p invalid cost matrix object cost matrix is infeasible OO numpy._core._multiarray_umath numpy.core._multiarray_umath _ARRAY_API _ARRAY_API is NULL pointer cost_matrix maximize _lsap linear_sum_assignment vector::_M_default_append expected a matrix (2-D array), got a %d array           matrix contains invalid numeric entries _ARRAY_API is not PyCapsule object      module compiled against ABI version 0x%x but this version of numpy is 0x%x      module was compiled against NumPy C-API version 0x%x (NumPy 1.23) but the running NumPy has C-API version 0x%x. Check the section C-API incompatibility at the Troubleshooting ImportError section at https://numpy.org/devdocs/user/troubleshooting-importerror.html#c-api-incompatibility for indications on how to solve this problem.       FATAL: module compiled as unknown endian        FATAL: module compiled as little endian, but detected different endianness at runtime   numpy._core.multiarray failed to import Solves the rectangular linear sum assignment.   Solve the linear sum assignment problem.

Parameters
----------
cost_matrix : array
    The cost matrix of the bipartite graph.

maximize : bool (default: False)
    Calculates a maximum weight matching if true.

Returns
-------
row_ind, col_ind : array
    An array of row indices and one of corresponding column indices giving
    the optimal assignment. The cost of the assignment can be computed
    as ``cost_matrix[row_ind, col_ind].sum()``. The row indices will be
    sorted; in the case of a square cost matrix they will be equal to
    ``numpy.arange(cost_matrix.shape[0])``.

See Also
--------
scipy.sparse.csgraph.min_weight_full_bipartite_matching : for sparse inputs

Notes
-----

The linear sum assignment problem [1]_ is also known as minimum weight
matching in bipartite graphs. A problem instance is described by a matrix
C, where each C[i,j] is the cost of matching vertex i of the first partite
set (a 'worker') and vertex j of the second set (a 'job'). The goal is to
find a complete assignment of workers to jobs of minimal cost.

Formally, let X be a boolean matrix where :math:`X[i,j] = 1` iff row i is
assigned to column j. Then the optimal assignment has cost

.. math::
    \min \sum_i \sum_j C_{i,j} X_{i,j}

where, in the case where the matrix X is square, each row is assigned to
exactly one column, and each column to exactly one row.

This function can also solve a generalization of the classic assignment
problem where the cost matrix is rectangular. If it has more rows than
columns, then not every row needs to be assigned to a column, and vice
versa.

This implementation is a modified Jonker-Volgenant algorithm with no
initialization, described in ref. [2]_.

.. versionadded:: 0.17.0

References
----------

.. [1] https://en.wikipedia.org/wiki/Assignment_problem

.. [2] DF Crouse. On implementing 2D rectangular assignment algorithms.
       *IEEE Transactions on Aerospace and Electronic Systems*,
       52(4):1679-1696, August 2016, :doi:`10.1109/TAES.2016.140952`

Examples
--------
>>> import numpy as np
>>> cost = np.array([[4, 1, 3], [2, 0, 5], [3, 2, 2]])
>>> from scipy.optimize import linear_sum_assignment
>>> row_ind, col_ind = linear_sum_assignment(cost)
>>> col_ind
array([1, 0, 2])
>>> cost[row_ind, col_ind].sum()
5
     cannot create std::vector larger than max_size()                                                         ;d         pP      8  0   t  p  0  0  <               zR x  $      Hp   FJw ?;*3$"       D   p   BJP B(A0A8DXBBM]PBBM
8A0A(B BBBJn
8A0A(B BBBH   4      ;   AHD 
MAHZ
CAJ     x?    A}   P   (      KBE B(D0A8H@
8A0A(B BBBFPX   |  H   FEB E(H0H8
0A(B BBBH
0A(B BBBH  T         TEI I(D0E8G@
8A0A(B BBBA@  H   0  T   LBB B(A0A8DP
8D0A(B BBBK       zPLR x]!    L   $   (  {   BBB B(A0A8G
8D0A(B BBBE    t      p        d           A                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         `             m             3             B             P                           0             m                           m                    o    `                                
                                  o                                        @             0	                   	              o          o           o    V      o                                                                                                                                                                           m                      6      F      V      f      v                                                                  &      6      F      V      f      v                            @      @                                                             @      C      `q                                                              @      p             C                                              GCC: (GNU) 14.2.1 20250110 (Red Hat 14.2.1-7)            GA$3a1                      GA$3a1                       GA$3a1 0      0               GA$3a1       i               GA$3a1 0      0               GA$3a1 0      0               GA$3a1                      GA$3a1 0      0                                                                   *                  C                    N                   P                   c                    y     q                  m                   `                   m                                  
    p                 p                  q                  p      h            `q      @       C                        P                                        +                 q                  PM                  0                  o              	    @-            >    (                 q                  m                  0(                  @(      ?       M    )                m                 	                                                          >                     Q                     b                      q                                                                                                                                                                                               5  "                   P                     e                     w                                                                                        @      ;                                                                                          
                                          +                     K                     ]                     t                                           rectangular_lsap.cpp _ZL5solvellPdbPlS0_ _ZL5solvellPdbPlS0_.cold crtstuff.c deregister_tm_clones __do_global_dtors_aux completed.0 __do_global_dtors_aux_fini_array_entry frame_dummy __frame_dummy_init_array_entry _lsap.c kwlist.0 PyArray_API moduledef lsap_methods __FRAME_END__ _ZSt16__introsort_loopIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEElNS0_5__ops15_Iter_comp_iterIZ12argsort_iterIlES5_RKS3_IT_SaISA_EEEUlllE_EEEvSA_SA_T0_T1_ DW.ref.__gxx_personality_v0 __GNU_EH_FRAME_HDR _fini _GLOBAL_OFFSET_TABLE_ _Z12argsort_iterIlESt6vectorIlSaIlEERKS0_IT_SaIS3_EE _ZSt16__insertion_sortIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEENS0_5__ops15_Iter_comp_iterIZ12argsort_iterIlES5_RKS3_IT_SaISA_EEEUlllE_EEEvSA_SA_T0_ __TMC_END__ __dso_handle solve_rectangular_linear_sum_assignment _ZNSt13_Bvector_baseISaIbEE13_M_deallocateEv _ZSt13__adjust_heapIN9__gnu_cxx17__normal_iteratorIPlSt6vectorIlSaIlEEEEllNS0_5__ops15_Iter_comp_iterIZ12argsort_iterIlES5_RKS3_IT_SaISA_EEEUlllE_EEEvSA_T0_SH_T1_T2_ _DYNAMIC _init PyExc_ImportError _ZSt20__throw_length_errorPKc@GLIBCXX_3.4 memset@GLIBC_2.2.5 PyExc_ValueError __gmon_start__ _ZdlPvm@CXXABI_1.3.9 PyCapsule_Type PyExc_TypeError PyExc_ModuleNotFoundError PyErr_Format _ITM_deregisterTMCloneTable PyErr_ExceptionMatches _ITM_registerTMCloneTable PyArg_ParseTupleAndKeywords __cxa_finalize@GLIBC_2.2.5 PyEval_RestoreThread PyEval_SaveThread PyExc_RuntimeError memmove@GLIBC_2.2.5 Py_BuildValue PyObject_GetAttrString PyInit__lsap PyErr_Print _Py_Dealloc PyImport_ImportModule PyErr_Clear PyModule_Create2 PyErr_SetString __gxx_personality_v0@CXXABI_1.3 _Znwm@GLIBCXX_3.4 _Unwind_Resume@GCC_3.0 memcpy@GLIBC_2.14 PyCapsule_GetPointer  .symtab .strtab .shstrtab .note.gnu.build-id .gnu.hash .dynsym .dynstr .gnu.version .gnu.version_r .rela.dyn .rela.plt .init .text .fini .rodata .eh_frame_hdr .eh_frame .gcc_except_table .init_array .fini_array .data.rel.ro .dynamic .got .got.plt .data .bss .comment .gnu.build.attributes                                                                                 8      8      $                              .   o       `      `      $                             8                         0                          @                                                      H   o       V      V      D                            U   o                                               d             0	      0	                                 n      B       @      @                                x                                                         s                           p                            ~                         F              @                            0      0                                                  @       @      P                                          PM      PM      d                                           M      M      $                                          P      P      ]                                           m      ]                                                m      ]                                                m      ]                                                 m      ]                                              o      _      P                                          o      _                                                p      `                                                  q      a                                         0               a      .                                                a                                                          b      `         #                 	                      Xi                                                         o      "                             