You are here

1 post / 0 new
#1

I'm using the python 3.8 version of PyRosetta and ubuntu 20.04 windows subsystem. I was able to download and install PyRosetta and it passed all the required tests. So subsequently I continued to load the enzyme and complex structures as molfiles. I've found that I had to change the molfile into a params file and the only way to do that was to use the module "molfile2params". In the original file of PyRosetta, there was no such file so I had to download it externally. I've installed it and located it and fixed some bugs so got it to work. I understood it worked because it gave me the -h text.  But to check whether it was working or not I didn't give any structure at first so my code in ubuntu was "python3 molfile_to_params.py". But when I tried to give it a molfile, it gave me this line of error.

Traceback (most recent call last):

File "molfile_to_params.py", line 1325, in <module>

sys.exit(main(sys.argv[1File "molfile_to_params.py",

line 1258, in molfiles = list(read_mdl_sdf(infile, do_find_rings=False))

NameError: name 'read_mdl_sdf' is not defined

When I went to check the problem myself, i went into the source code myself and understood that the problem was caused from:

if infile_lc.endswith(".mol2"):
elif infile_lc.endswith(".mol") or infile_lc.endswith(".mdl") or infile_lc.endswith(".sdf"):
else:
print("Unrecognized file type, must be .mol/.sdf or .mol2!")
return 6

this part. The functions read_mdl_sdf and read_tripos_mol2 wasn't defined in anywhere in the code! And the definiton obviously wasn't from another module. I've searched for it in this very website and in google at general but didn't got any satifactory answer for the fixation of the problem.

The only on-point answer was from this website: but it also doesn't fix my problem: https://www.rosettacommons.org/manuals/rosetta3.3_user_guide/d3/d5c/namespacerosetta__py_1_1io_1_1mdl__molfile.html#a79ed6f062b6667d47808aa8fda3001c8

I suspect my error is caused by a lacking of definition on my code or something else that I don't understand. For the people to observe the problem themselves, I'm going to put the molfile_to_params.py python file(as plain text because it doesn't allow python files). I have limited time to fix this problem and I would be very thankful if the forums can help me fixing it.

Thanks!

AttachmentSize
67.27 KB
Category:
Post Situation:
Wed, 2021-01-13 22:14
egecav