parameters name in inserted modules.
Posted: Wed Aug 21, 2013 12:50 am
Hi all,
I have strange problem with using NEURON+Python.
According Hines et.al. 2009 'NEURON and Python', parameters of inserted modules should be accessible through object's attribute with same name as SUFFIX.
For example, I inserted a simple module:
and tried manipulate with leak reversal potential:
NEURON returned error:
Should I use suffix instead object's attribute? BTW this form works perfect.
Thank you,
Ruben
I have strange problem with using NEURON+Python.
According Hines et.al. 2009 'NEURON and Python', parameters of inserted modules should be accessible through object's attribute with same name as SUFFIX.
Code: Select all
soma = h.Section()
soma.insert ('pas')
soma.pas.g = 0.0003
Code: Select all
TITLE passive (leak) membrane channel
UNITS {
(mV) = (millivolt)
(mA) = (milliamp)
}
NEURON {
SUFFIX vcnleak
NONSPECIFIC_CURRENT i
RANGE g, erev
}
PARAMETER {
v (mV)
g = .001 (mho/cm2)
erev = -65 (mV)
}
ASSIGNED { i (mA/cm2)}
BREAKPOINT {
i = g*(v - erev)
}
Code: Select all
self.soma = h.Section(name='soma', cell=self)
self.soma.insert('vcnleak')
self.soma.vcnleak.g = 1./10000.
Code: Select all
nrngui -nogui -python RaM03.py
NEURON -- Release 7.2 (562:42a47463b504) 2011-12-21
Duke, Yale, and the BlueBrain Project -- Copyright 1984-2008
See http://www.neuron.yale.edu/credits.html
loading membrane mechanisms from /home/rth/i686/.libs/libnrnmech.so
.....
.....
self.soma.vcnleak.g = 1./10000.
AttributeError: 'nrn.Section' object has no attribute 'vcnleak'
Code: Select all
h('soma g_vcnleak = 1./10000. ')
Ruben