Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Install pybrain on python 3.2

I'm trying to install pybrain on python 3.2. It says here: https://github.com/pybrain/pybrain/pull/85 that it should work. However it does not for me.

I tried:

$export PYTHONPATH=$PYTHONPATH:'/home/luis/Documents/pybrain/'https://github.com/pybrain/pybrain/pull/85

which works well for python 2.7.

Did somebody get it to work?

like image 429
Luis Avatar asked Mar 04 '13 23:03

Luis


2 Answers

After hours of "what the hell?!"s I installed it. First the installer suggested is not updated for Python3 so I installed Distribute. With that installed I was able to use python setup.py install in the directory where I unrared pybrain. It gave a ton of errors. So I found this article (god bless google translate) and used 2to3 on pybrain directory. After I tried to install it again it gave an error on from string import split so I edited the file and removed that line (it is not needed really) and tried yet another time. This time no errors occurred and I was able to import pybrain without any problems. The same problem with the from string import split occurs in utilities.py again, so edit that line too.

I used 2to3 to turn examples to python3 too. benchmarkplots.py seems to work.

like image 66
P_Rein Avatar answered Sep 20 '22 08:09

P_Rein


Update: pybrain now supports python3
Here's how to install if you run into trouble

pip install https://github.com/pybrain/pybrain/archive/0.3.3.zip

Or just grab latest github pybrain release.

like image 42
Lazik Avatar answered Sep 24 '22 08:09

Lazik