single_cell_parser
❭ cell
❭ PySection
PySection¶
-
class single_cell_parser.cell.PySection(name=
None
, cell=None
, label=None
)¶ Wrapper around
nrn.Section
providing additional functionality for geometry and mechanisms.NEURON sections are objects of the form
__nrnsec_0x------------
, where the dashed code represents the memory pointer. Each section consists ofnseg
segments of equal length. Each segment is represented by__nrnsec_0x------------(x)
, which looks similar to the section representation, but has an additional(x)
: a relative coordinate representing the center point of the segment.Iterating the section will provide the individual segments. Each segment consists of one or more points. Accessing a segment’s biophysical properties can be done as
seg.<param>.<param_name>
.Example:
>>> sec = cell.soma >>> for seg in sec: ... print(seg.NaTa_t.gNaTa_tbar)
- Parameters:¶
name (str, optional) – name of the section
cell (Cell, optional) – reference to the cell object
label (str, optional) – label of the section
- Attributes:¶
- label_detailed¶
Detailed label of the section (e.g. “oblique”, “basal”, “trunk”). These are manually assigned or automatically generated by
augment_cell_with_detailed_labels()
. Used inscale_by_detailed_compartment()
.- Type:¶
str, optional
- segPts¶
list of segment centers (x coordinate). Useful for looping akin to the hoc function
for(x)
. Excluding 0 and 1.- Type:¶
list
- Methods:¶
set_3d_geometry
(pts, diams)Invokes NEURON 3D geometry setup.
set_segments
(nrOfSegments)Set spatial discretization.
_get_seg_conductance
(seg, var, param_name)Get the conductance of a segment.
get_range_conductances
(range_vars, density)Get the transmembrane conductance of each range variable separately.
Computes the diameter of each segment in this section.
Computes total area of all NEURON segments in this section
Computes the bounding box around the 3D coordinates.
Computes the relative position of 3D points along the section.
Computes the 3D center points of each segment in this section.
Record the membrane voltage at every point in this section.
Reinitialize votage recordings
Re-initialize the range mechanism recordings.
_init_range_var_recording
(var, mech)Initialize recording of a range mechanism.