savvaki/LPDM

about main.py

MSL502 opened this issue · 3 comments

Dear writer, I have the following question

Traceback (most recent call last):
File "/home/mmsys/pycharm-community-2022.1.3/plugins/python-ce/helpers/pydev/pydevd.py", line 1491, in _exec
pydev_imports.execfile(file, globals, locals) # execute the script
File "/home/mmsys/pycharm-community-2022.1.3/plugins/python-ce/helpers/pydev/_pydev_imps/_pydev_execfile.py", line 18, in execfile
exec(compile(contents+"\n", file, 'exec'), glob, loc)
File "/media/mmsys/6f1091c9-4ed8-4a10-a03d-2acef144d2e1/SXY/LPDM-main/main.py", line 429, in
parser = Trainer.add_argparse_args(parser)
AttributeError: type object 'Trainer' has no attribute 'add_argparse_args'
python-BaseException

I would really appreciate it if you could help me with this problem

Could you make sure that you followed these steps, you need to run these commands:

  • conda env create -f environment.yml
  • conda activate lpdm
  • python main.py --base configs/train/lpdm_lol.yaml --gpu 0,

I see that you are using pycharm based on your issue, but try to run the code from the terminal.

Let me know if this helps.

I am going to close this issue, if the problem still persists please open a new issue.

MSL502 commented

Thanks to the author, the problem has been solved