Tsinghua-MARS-Lab / DenseTNT

MIT License
470 stars 122 forks source link

How to debug it #51

Open 9p15p opened 1 year ago

9p15p commented 1 year ago

The program is unable to pause at breakpoints. I tried some tools including pydevd and pudb, but they all failed. It seems to be caused by multiprocessing. How could I operate single step debugging.

GentleSmile commented 1 year ago

What about setting --distributed_training 1 and using pdb.set_trace() to debug?

9p15p commented 1 year ago

I have tried, but it didn't work.

I add a lineimport pdb; pdb.set_trace() after https://github.com/Tsinghua-MARS-Lab/DenseTNT/blob/a0e3b8a51aecf9f9046db4fb72e2793684c96e69/src/run.py#L158

GentleSmile commented 1 year ago

We updated the code just now so that you can set --distributed_training 0 to turn off multiprocessing.