Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JOSS review] Criptic error running example #22

Closed
rvhonorato opened this issue Jan 12, 2022 · 3 comments
Closed

[JOSS review] Criptic error running example #22

rvhonorato opened this issue Jan 12, 2022 · 3 comments

Comments

@rvhonorato
Copy link

When running the provided example:

# example/benzene_5wiu.py
import pyscreener as ps
import ray
ray.init()

metadata = ps.build_metadata("vina")
virtual_screen = ps.virtual_screen("vina", ["integration-tests/inputs/5WIU.pdb"], (-18.2, 14.4, -16.1), (15.4, 13.9, 14.5), metadata, ncpu=8)

scores = virtual_screen("c1ccccc1")
scores
$ python example/benzene_5wiu.py 
2022-01-12 14:20:06,884 INFO services.py:1338 -- View the Ray dashboard at http://127.0.0.1:8265
Traceback (most recent call last):
  File "example/benzene_5wiu.py", line 9, in <module>
    scores = virtual_screen("c1ccccc1")
  File "/Users/rodrigo/repos/pyscreener/pyscreener/docking/screen.py", line 169, in __call__
    planned_simulationsss = self.plan(sources, smiles)
  File "/Users/rodrigo/repos/pyscreener/pyscreener/docking/screen.py", line 243, in plan
    planned_simulationsss = [
  File "/Users/rodrigo/repos/pyscreener/pyscreener/docking/screen.py", line 244, in <listcomp>
    [
  File "/Users/rodrigo/repos/pyscreener/pyscreener/docking/screen.py", line 245, in <listcomp>
    [
  File "/Users/rodrigo/repos/pyscreener/pyscreener/docking/screen.py", line 246, in <listcomp>
    replace(
  File "/Users/rodrigo/software/anaconda3/envs/pyscreener_env/lib/python3.8/dataclasses.py", line 1264, in replace
    raise TypeError("replace() should be called on dataclass instances")
TypeError: replace() should be called on dataclass instances
(prepare_receptors pid=47498) Traceback (most recent call last):
(prepare_receptors pid=47498)   File "/Users/rodrigo/ADFRsuite-1.0/CCSBpckgs/AutoDockTools/Utilities24/prepare_receptor4.py", line 9, in <module>
(prepare_receptors pid=47498)     from MolKit import Read
(prepare_receptors pid=47498) ImportError: No module named MolKit
(prepare_receptors pid=47498) 
(prepare_receptors pid=47498) ERROR: failed to convert "integration-tests/inputs/5WIU.pdb"
@rvhonorato
Copy link
Author

Actually just as I posted this I realized it is because there was something wrong with my ADFRsuite-1.0 suite. Also it seems that pyscreener depends on this prepare_receptor, which is still python2, very unfortunate...

I see that ADFR is also available as a conda package: https://anaconda.org/hcc/adfr-suite, is this a viable substitute?

@davidegraff
Copy link
Collaborator

It is unfortunate that prepare_receptor is still in python2. Even more unfortunate is that openbabel functions to prepare receptor result in different files than prepare_receptor, so it doesn't seem like there's a python3 method by which to do this. Though I guess, there's no native python3 support for any of these docking programs, which is the whole thing we're trying to address here (basically hiding all the ugly parts of integrating docking into your own python workflow)

@davidegraff
Copy link
Collaborator

re: conda ADFR- I haven't tried with that package. The only requirement for it to work is that prepare_receptor is accessible on your path and produces the same results as the prepare_receptor when installing from source. Though I suspect that latter point is not much concern here...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants