unload mechanisms dll

When Python is the interpreter, what is a good
design for the interface to the basic NEURON
concepts.

Moderator: hines

Post Reply
a.negrean
Posts: 1
Joined: Wed Aug 29, 2018 11:32 pm

unload mechanisms dll

Post by a.negrean » Thu Aug 30, 2018 11:06 am

Hi,

I am using Neuron ver. 7.5 master(4d65a2c+) 2017-08-17 under Linux with Python 3.6.4 and I am importing mechanisms with h.nrn_load_dll(). This works fine the first time, but if this is done the second time, the python kernel crashes. I could of course keep track in a variable if the dll has been loaded already, but I wonder, is there is a way to cleanly unload the dll? I am thinking of a scenario where I'd like to work with multiple dll's that contain different membrane mechanism configurations without putting multiple versions of the same mechanism in the same dll.

I also tried reloading the neuron module like this:
import importlib
importlib.reload(neuron)

but the python kernel is still crashing.
Thank you!

ted
Site Admin
Posts: 5369
Joined: Wed May 18, 2005 4:50 pm
Location: Yale University School of Medicine
Contact:

Re: unload mechanisms dll

Post by ted » Tue Sep 04, 2018 9:16 am

is there is a way to cleanly unload the dll?
No. Exit NEURON, then restart NEURON.

Post Reply