pythonpackageanacondapybrain

PyBrain in Anaconda - ImportError: No module named 'structure'


I'm looking for a way to use numpy, scipy and pybrain in python. If I try to install those I get the error:

Microsoft Visual C++ 10.0 is required (Unable to find vcvarsall.bat).

I have installed visual studio but it still doesn't work. I have tried setting up an environment with conda including numpy and scipy and then installing pybrain in it using pip but when I try to import it I get the error:

import pybrain
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\Users\Lucas\Anaconda3\envs\brain\lib\site-packages\pybrain\__init__.py", line 1, in <module>
    from structure.__init__ import *
ImportError: No module named 'structure'

What should I do?


Solution

  • This seems to be an issue with the library when used from Python 3 and installed using pip. The latest version listed is 0.3.3, but I'm still getting v0.3.0 when installing.

    Try installing numpy and scipy in Anaconda, then (after activating the conda environment) install directly from the git repo:

    pip install git+https://github.com/pybrain/pybrain.git@0.3.3

    This did the trick for me.