Page 1 of 1
How can I import neuron in an Python IDE under MSWin?
Posted: Tue May 13, 2008 11:11 am
I tried to import neuron in Python(rather than in nrniv_python),but IDLE prompted an error, and I know it was because there was no neuron module. How can I fix the problem?
p.s. I used setup.exe to install NEURON rather than complied source code
Posted: Tue May 13, 2008 9:09 pm
At present, the setup.exe is limited to installing a version of NEURON that can
only be imported into a cygwin version of Python (i.e the same version of python
that the nrniv.exe program embeds.) Sadly, to import NEURON into a native mswin
build of Python you would need to build NEURON from the sources. This is done by
configuring with something like:
../nrn/configure --prefix=/home/hines/neuron/p25 --srcdir=/home/hines/neuron/nrn --with-nrnpython=/cygdrive/c/Python25/python
which will compile under MinGW libraries. Such a build is most easily accomplished
with a full cygwin development environment.
Depending on whether you have Python2.4 or Python2.5 you would then move
the hocmodule.dll to the proper directory with the proper name. You can see why
I am currently only supporting embedding python via the setup.exe. At some point
in the future, and if the need to extend python on mswin becomes common, I will
provide a package for that purpose. Maybe someone would like to help me prepare
a proper egg or whatever it is called. At present I am unfamiliar with the proper
preparation of python modules or where to put them and how to invoke remote installation.
Posted: Wed May 14, 2008 9:21 am
Hello , hines
I followed your instruction,but I encountered 2 problems in the last step"make mswin". They are as follows:
1.cp: can't stat â€œ/../bin/cygIVhines-3.dllâ€
Posted: Wed May 14, 2008 9:00 pm
[quote] 1.cp: can't stat â€œ/../bin/cygIVhines-3.dllâ€