protocaller / ProtoCaller

Full automation of relative protein-ligand binding free energy calculations in GROMACS
http://protocaller.readthedocs.io
GNU General Public License v3.0
43 stars 15 forks source link

Performing Free Energy Calculations failed #14

Closed kexul closed 3 years ago

kexul commented 3 years ago

It seems like there were some bugs in ProtoCaller/Utils/fileio.py , when I run the 'Performing Free Energy Calculation' example, the error raised.

Traceback (most recent call last):
  File "run.py", line 41, in <module>
    with workdir:
  File "/root/anaconda3/envs/uii/lib/python3.7/site-packages/ProtoCaller/Utils/fileio.py", line 69, in __enter__
    _os.makedirs(self.dirname)
  File "/root/anaconda3/envs/uii/lib/python3.7/os.py", line 223, in makedirs
    mkdir(name, mode)
FileNotFoundError: [Errno 2] No such file or directory: ''

I ran the code by : python run.py --mode bound --workdir /root/proto/kinase/2OJ9/mola~molb/ , the kinase directory were generated by protocaller, and there were complex_final.gro and complex_final.top files in the mola~molb directory.

msuruzhon commented 3 years ago

This seems to be just some weird behaviour by os.makedirs when there is a trailing slash. If you remove the final slash, it should work.

msuruzhon commented 3 years ago

I have now pushed a small update that should take care of this behaviour.