Open ArvinKhoshboresh opened 1 month ago
Hi! I haven't looked at this project for a few years - I'd imagine the malloc
in auction_.pyx are not being freed properly.
I won't be able to have a look at it for a little while - will post any updates here when I am able to fix it.
Hi! No issue, thanks for writing it in the first place. Its been very useful up to now regardless.
I'm not a very experienced C or Cython programmer but I'll clone the project and see if I can fix it myself as well.
I've been trying to use this package to solve a very large (1M x 1M cost matrix, though very sparse) linear assignment problem. doing this causes a segmentation fault even when passing cardinality_check=False.
To get around this, I cut up my problem into many smaller problems of varying sizes (10kx10k to 300x300) because this is suboptimal but feasible for my use-case. My program will start to solve the smaller problems, but will eventually crash, but never at one particular problem.
To isolate the problem, I wrote the following code to remove the other elements of my code:
When this is done, memory usage climbs very quickly. Our compute has 200gb ram and a larger swap, and it quickly exceeds this.
Notably this only happens when passing a sparse matrix, and not a dense matrix. I believe it still happens with the dense matrix but it appears to be much much slower.