'nrniv -python' Not Working

Post Reply
Posts: 51
Joined: Fri Mar 14, 2008 7:57 am

'nrniv -python' Not Working

Post by roybens »

I installed Neuron 7.4 from the binary package from Windows and set up my PYTHONPATH and NEURONHOME so everything points to the correct directories.
When I run python 2.7 and import neuron, the import works and I can load files and access information from neuron.h.
However, when I try to run 'nrniv -python', this is the error message that is given to me:

Code: Select all

NEURON -- Release 7.4 (1370:16a7055d4a86) 2015-11-09
Duke, Yale, and the BlueBrain Project -- Copyright 1984-2015
See http://www.neuron.yale.edu/neuron/credits

Python not available
Additionally, when I loading the neuron dll from Python, this is what happens:

Code: Select all

>>> from neuron import nrn_dll
>>> dll = nrn_dll()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "c:\nrn\lib\python\neuron\__init__.py", line 454, in nrn_dll
    raise Exception('unable to connect to the NEURON library')
Exception: unable to connect to the NEURON library
According to this thread: viewtopic.php?f=6&t=2005, it says that I need to build Neuron from source in order to access the Neuron dll, but that thread is over 5 years old. Is it possible to get 'nrniv -python' working and run 'nrn_dll()' without any errors without building from source?
Site Admin
Posts: 1619
Joined: Wed May 18, 2005 3:32 pm

Re: 'nrniv -python' Not Working

Post by hines »

The "python not available" is unusual for a version of NEURON that is built with python.
Assuming that this is some kind of environment problem, it make take a few rounds of experiments to figure it out. So let's take this to email and send the
results of the following to michael dot hines at yale dot edu.

Are you using the x86_64 or i686 version of NEURON. What windows os are you using. What is your cpu type.

Start the bash terminal. What is the result of

for each of the above three that are not empty, unset them and then what is the result of

What is the result of launching
nrniv -nopython
nrniv -python

what python are you using
import sys
Post Reply