I successfully installed modeller through conda install modeller and also change the license key in config.py but when I try to run :
from modeller import *
it shows the following error :
ModuleNotFoundError Traceback (most recent call last)<ipython-input-1-80c5cec1a705> in <module>()----> 1 from modeller import * ModuleNotFoundError: No module named 'modeller'
plz help me
Hi Anas,
Did you activate the conda environment into which you have installed modeller?
What command lines did you use to install modeller and to start ipython?
Best, Ajasja
On Mon, Aug 31, 2020 at 12:38 PM Anas Jamshed anasjamshed1994@gmail.com wrote:
> I successfully installed modeller through conda install modeller and also > change the license key in config.py but when I try to run : > > > from modeller import * > > it shows the following error : > > ModuleNotFoundError Traceback (most recent call last)<ipython-input-1-80c5cec1a705> in <module>()----> 1 from modeller import * > ModuleNotFoundError: No module named 'modeller' > > > > plz help me > _______________________________________________ > modeller_usage mailing list > modeller_usage@salilab.org > https://salilab.org/mailman/listinfo/modeller_usage >
Hello,
It is probably unrelated, but I also had problems with running Modeller from Anaconda on Windows. Apparently the complicated Modeller directory structure used in the standalone Windows version is not relevant under Anaconda.
Traceback (most recent call last): File "model_test.py", line 1, in <module> from modeller import * File "C:\Users\genie.conda\envs\modeller\Library\modeller\modlib\modeller__init__.py", line 73, in <module> __dll_directory = os.add_dll_directory(dpath) File "C:\Users\genie.conda\envs\modeller\lib\os.py", line 1109, in add_dll_directory cookie = nt._add_dll_directory(path) FileNotFoundError: [WinError 3] The system cannot find the path specified: 'C:/Users/genie/.conda/envs/modeller\Library\modeller\lib\x86_64-w64'
If I use the standalone Modelled by explicitly calling modenv.bat from the activated conda (to get the right Python), everything works fine.
Best wishes Eugene
From: Anas Jamshed Sent: Monday, August 31, 2020 10:35 PM To: modeller_usage@salilab.org Subject: [modeller_usage] problem in anaconda
I successfully installed modeller through conda install modeller and also change the license key in config.py but when I try to run :
from modeller import *
it shows the following error :
ModuleNotFoundError Traceback (most recent call last) <ipython-input-1-80c5cec1a705> in <module>() ----> 1 from modeller import *
ModuleNotFoundError: No module named 'modeller'
plz help me
-------------------------------------------------------------------------------- _______________________________________________ modeller_usage mailing list modeller_usage@salilab.org https://salilab.org/mailman/listinfo/modeller_usage
On 8/31/20 1:02 PM, Eugene Radchenko wrote: > It is probably unrelated, but I also had problems with running Modeller > from Anaconda on Windows. Apparently the complicated Modeller directory > structure used in the standalone Windows version is not relevant under > Anaconda. ... > File "C:\Users\genie.conda\envs\modeller\lib\os.py", line 1109, in > add_dll_directory > cookie = nt._add_dll_directory(path) > FileNotFoundError: [WinError 3] The system cannot find the path > specified:
I'm guessing you are using Python 3.8? You're absolutely right - the standalone installer includes some logic to make it work with multiple Python versions, which isn't necessary with Anaconda since the Anaconda environment handles that already. It's a harmless addition for Python up to 3.7 as it just adds a (non-existent) directory to the search path, but Python 3.8 changed the way the path was handled, and (as you saw) reports an error if a path element doesn't exist.
The simple fix here is to edit Modeller's top-level __init__.py (on your system in C:/Users/genie/.conda/envs/modeller/Library/modeller/modlib/modeller) and remove this logic, lines 30 through 94 (or just the call to add_dll_directory() on lines 72 & 73).
I'll roll this fix into the 9.25 release, due out next week.
Ben Webb, Modeller Caretaker
On 8/31/20 12:35 PM, Anas Jamshed wrote: > I successfully installed modeller through conda install modeller and > also change the license key in config.py but when I try to run : > > > from modeller import * > > it shows the following error : > > ModuleNotFoundError Traceback (most recent call last) > <ipython-input-1-80c5cec1a705> in<module>() > ----> 1from modellerimport * > > ModuleNotFoundError: No module named 'modeller'
My guess here is that you installed Modeller in one conda environment and you're running ipython in a different conda environment (or perhaps not even in conda at all). As others have said though, we would need more information to be able to help you.
Ben Webb, Modeller Caretaker
participants (4)
-
Ajasja Ljubetič
-
Anas Jamshed
-
Eugene Radchenko
-
Modeller Caretaker