LLNL / MemSurfer

MemSurfer is a software tool to compute bilayer membrane surfaces.
GNU General Public License v3.0
24 stars 9 forks source link

Error when trying to import memsurfer #2

Closed MSiggel closed 4 years ago

MSiggel commented 4 years ago

Hi, I seemingly successfully installed memsurfer without issues. However, when I try to import the library

import memsurfer 

I get the following error:

Traceback (most recent call last):
  File "/home/tb/masiggel/anaconda2/envs/python3/lib/python3.8/site-packages/memsurfer-1.0.0-py3.8-linux-x86_64.egg/memsurfer/pymemsurfer.py", line 14, in swig_import_helper
    return importlib.import_module(mname)
  File "/home/tb/masiggel/anaconda2/envs/python3/lib/python3.8/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 973, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'memsurfer._pymemsurfer'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "import_memsurf.py", line 7, in <module>
    import memsurfer
  File "/home/tb/masiggel/anaconda2/envs/python3/lib/python3.8/site-packages/memsurfer-1.0.0-py3.8-linux-x86_64.egg/memsurfer/__init__.py", line 15, in <module>
    from .membrane import Membrane
  File "/home/tb/masiggel/anaconda2/envs/python3/lib/python3.8/site-packages/memsurfer-1.0.0-py3.8-linux-x86_64.egg/memsurfer/membrane.py", line 21, in <module>
    from . import pymemsurfer
  File "/home/tb/masiggel/anaconda2/envs/python3/lib/python3.8/site-packages/memsurfer-1.0.0-py3.8-linux-x86_64.egg/memsurfer/pymemsurfer.py", line 17, in <module>
    _pymemsurfer = swig_import_helper()
  File "/home/tb/masiggel/anaconda2/envs/python3/lib/python3.8/site-packages/memsurfer-1.0.0-py3.8-linux-x86_64.egg/memsurfer/pymemsurfer.py", line 16, in swig_import_helper
    return importlib.import_module('_pymemsurfer')
  File "/home/tb/masiggel/anaconda2/envs/python3/lib/python3.8/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
ImportError: memsurfer/MemSurfer/external/lib/libvtkWrappingPython27Core-8.1.so.1: undefined symbol: _Py_ZeroStruct
bhatiaharsh commented 4 years ago

Hi. It seems your python configuration is inconsistent. Memsurfer is trying to use python3.8, but the vtk libs that you built are using python2.7.

what does your python default to?

MSiggel commented 4 years ago

I mistakenly ran the install_deps.sh outside of the correct conda environment. running within the right conda environment fixed this issue.

Thanks a lot for your help and looking forward to testing your tool now!