Kei18 / py-lacam

Minimal Python implementation of LaCAM* for MAPF
https://kei18.github.io/lacam/
MIT License
13 stars 3 forks source link

Question about Open form #2

Open ShuaiZhou302 opened 3 months ago

ShuaiZhou302 commented 3 months ago

Hello sir: lately i been working on reproduction of your lacam2 It is very enlightning! my question is: Is it particularly important to represent the OPEN as a deque Cause i use minimum heap as the Open, and i find out my fully implementation is 1 second slower than your python random configeration generat version. both of tem reach the optimal solution. so i kinda wonder is it the form makes it different or just my code proficiency Thanks again!

Kei18 commented 3 months ago

Hi, I hope you like the MAPF stuff!

LaCAM works with any moderate data structure as an OPEN list. But my observation so far is that a simple stack (or deque) structure seems powerful because the search becomes depth-first style. Priority queues in general require extra overhead for insert/pop operations, which could reduce speed.

If you find the effective metric for the priority queue, it might work well - it's an open question.

Cheers, Keisuke

ShuaiZhou302 commented 3 months ago

Thank you sir !, i have test my code again and again and finds out it just a mistakes in my code makes it expand more constrain node. anyway, thanks for your help! clearly a simple deque is 0.2s faster than maintaining a queue in the sample test. It's kind people like you help me this rookie have the courage to face the difficulties of scientific research one after another!