0

I am trying to install mlabwrap but it is not working.

I downloaded it and I installed it as follow:

  • From command window I got into the mlabwrap folder
  • I typed python setup.py install
  • Everything is fine

I opened Pycharm and I typed from mlabwrap import mlab and sadly I got the following error.

Traceback (most recent call last):
 File "C:\Anaconda\lib\site-packages\IPython\core\interactiveshell.py", 
  line 2731, in run_code exec code_obj in self.user_global_ns, self.user_ns
 File "<ipython-input-2-7a02b1481f8f>", line 1, in <module>
  from mlabwrap import mlab
 File "C:\Program Files (x86)\JetBrains\PyCharm Community Edition    
  4.0.4\helpers\pydev\pydev_import_hook.py", line 21, in do_import module = 
  self._system_import(name, *args, **kwargs)
 ImportError: No module named mlabwrap
Jika
  • 1,556
  • 4
  • 16
  • 27
  • Do you have multiple Python installations on your machine? Looks like you may have installed mlabwrap into a different interpreter than the one used by PyCharm. – yole Mar 11 '15 at 21:21
  • yes I installed python from https://www.python.org/ and I installed Anaconda. Should I remove it or what else ? – Jika Mar 11 '15 at 21:27

1 Answers1

1

You have multiple Python interpreters on your system, and each of them has an independent set of packages. If you install a package into your main Python installation, it will not become available in Anaconda.

Try running this command to install mlabwrap into Anaconda:

 C:\Anaconda\python setup.py install
yole
  • 92,896
  • 20
  • 260
  • 197