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

Error when trying to import memsurfer #2

Closed
MSiggel opened this issue Nov 4, 2019 · 2 comments
Closed

Error when trying to import memsurfer #2

MSiggel opened this issue Nov 4, 2019 · 2 comments

Comments

@MSiggel
Copy link

MSiggel commented Nov 4, 2019

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
Copy link
Contributor

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
Copy link
Author

MSiggel commented Nov 6, 2019

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!

@MSiggel MSiggel closed this as completed Nov 6, 2019
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