Comprehensive Single Cell Analysis with bmtool¶
By Gregory Glickert
This tutorial demonstrates multiple methods to load neurons into bmtool's single cell analysis module, and shows how to apply various electrophysiological analysis techniques to any loaded cell model. We'll cover:
- Cell Loading Methods: Allen Database, NEURON HOC templates, and Python class-based models
- Analysis Techniques: Passive properties, Current clamp, Impedance (ZAP), and Frequency-Intensity (FI) curves
This notebook demonstrates that all analysis methods work consistently regardless of how the cell was loaded.
Part 1: Setup and Compilation¶
First, we compile the MOD files and set up the analysis environment. This section applies to all cell loading methods.
import os
import glob
import logging
import numpy as np
import matplotlib.pyplot as plt
from neuron import h
from bmtool.singlecell import (
Passive, CurrentClamp, ZAP, FI, Profiler, run_and_plot,
load_allen_database_cells
)
%matplotlib inline
# Disable warnings for cleaner output
logging.disable(logging.WARNING)
# if already compiled then lets delete the folder and force a recompile
if os.path.isdir('modfiles/x86_64'):
os.system("rm -rf modfiles/x86_64")
if os.path.isdir('modfiles/arm64'):
os.system("rm -rf modfiles/arm64")
# compile the mod files
if not os.path.isdir("modfiles/x86_64"):
os.chdir('modfiles')
os.system("nrnivmodl")
os.chdir("..")
/Users/gregglickert/miniconda3/envs/bmtk/bin/nrnivmodl:10: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html from pkg_resources import working_set
/usr/bin/xcrun /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles Mod files: "./AMPA_NMDA_STP.mod" "./CaDynamics.mod" "./Ca_HVA.mod" "./Ca_LVA.mod" "./GABA_A_STP.mod" "./Gfluct.mod" "./Ih.mod" "./Im.mod" "./Im_v2.mod" "./K_P.mod" "./K_T.mod" "./Kd.mod" "./Kv2like.mod" "./Kv3_1.mod" "./NaTa.mod" "./NaTs.mod" "./NaV.mod" "./Nap.mod" "./SK.mod" "./cadad.mod" "./cal2.mod" "./can_mig.mod" "./exp2syn_stp.mod" "./gap.mod" "./h_kole.mod" "./imCA3.mod" "./k.mod" "./kBK.mod" "./kap_BS.mod" "./kdmc_BS.mod" "./kdrCA3.mod" "./kdr_BS.mod" "./kdrinter.mod" "./leak.mod" "./na.mod" "./nainter.mod" "./napCA3.mod" "./natCA3.mod" "./nax_BS.mod" "./vecevent_coreneuron.mod" Creating 'arm64' directory for .o files. -> Compiling mod_func.cpp -> NMODL ../CaDynamics.mod -> NMODL ../AMPA_NMDA_STP.mod -> NMODL ../Ca_HVA.mod -> NMODL ../Ca_LVA.mod -> NMODL ../GABA_A_STP.mod -> NMODL ../Gfluct.mod -> NMODL ../Ih.mod -> NMODL ../Im.mod -> NMODL ../Im_v2.mod -> NMODL ../K_T.mod -> NMODL ../Kd.mod -> NMODL ../K_P.mod -> NMODL ../Kv2like.mod -> NMODL ../Kv3_1.mod -> NMODL ../NaTa.mod -> NMODL ../NaTs.mod -> NMODL ../NaV.mod -> NMODL ../Nap.mod -> NMODL ../SK.mod -> NMODL ../cadad.mod -> NMODL ../cal2.mod Warning: Default 2 of PARAMETER cao will be ignored and set by NEURON. Warning: Default 5e-05 of PARAMETER cai will be ignored and set by NEURON. -> NMODL ../can_mig.mod -> NMODL ../exp2syn_stp.mod -> NMODL ../gap.mod Warning: Default 2 of PARAMETER cao will be ignored and set by NEURON. Warning: Default 5e-05 of PARAMETER cai will be ignored and set by NEURON. -> NMODL ../h_kole.mod -> NMODL ../imCA3.mod -> NMODL ../k.mod Warning: Default 6.3 of PARAMETER celsius will be ignored and set by NEURON. -> NMODL ../kBK.mod -> NMODL ../kap_BS.mod -> NMODL ../kdmc_BS.mod -> NMODL ../kdrCA3.mod -> NMODL ../kdr_BS.mod -> NMODL ../kdrinter.mod Warning: Default -80 of PARAMETER ek will be ignored and set by NEURON. -> NMODL ../na.mod -> NMODL ../leak.mod -> NMODL ../nainter.mod Warning: Default 45 of PARAMETER ena will be ignored and set by NEURON. Warning: Default 6.3 of PARAMETER celsius will be ignored and set by NEURON. -> NMODL ../natCA3.mod -> NMODL ../napCA3.mod -> NMODL ../nax_BS.mod -> NMODL ../vecevent_coreneuron.mod -> Compiling CaDynamics.c -> Compiling AMPA_NMDA_STP.c Notice: ARTIFICIAL_CELL is a synonym for POINT_PROCESS which hints that it only affects and is affected by discrete events. As such it is not located in a section and is not associated with an integrator -> Compiling Ca_HVA.c -> Compiling Ca_LVA.c -> Compiling GABA_A_STP.c -> Compiling Gfluct.c -> Compiling Ih.c
Translating AMPA_NMDA_STP.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/AMPA_NMDA_STP.c
Translating Ca_HVA.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/Ca_HVA.c
Translating CaDynamics.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/CaDynamics.c
Thread Safe
Thread Safe
Thread Safe
Translating Ca_LVA.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/Ca_LVA.c
Translating GABA_A_STP.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/GABA_A_STP.c
Translating Gfluct.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/Gfluct.c
Thread Safe
Thread Safe
Notice: This mechanism cannot be used with CVODE
Thread Safe
Translating Ih.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/Ih.c
Translating Im.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/Im.c
Translating Im_v2.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/Im_v2.c
Thread Safe
Thread Safe
Thread Safe
Translating K_T.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/K_T.c
Translating K_P.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/K_P.c
Translating Kd.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/Kd.c
Thread Safe
Thread Safe
Thread Safe
Translating Kv2like.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/Kv2like.c
Translating Kv3_1.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/Kv3_1.c
Translating NaTa.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/NaTa.c
Thread Safe
Thread Safe
Thread Safe
Translating NaTs.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/NaTs.c
Translating NaV.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/NaV.c
Translating Nap.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/Nap.c
NEURON's CVode method ignores conservation
Thread Safe
Notice: LINEAR is not thread safe.
Thread Safe
Translating cadad.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/cadad.c
Translating SK.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/SK.c
Translating cal2.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/cal2.c
Thread Safe
Thread Safe
Thread Safe
Translating exp2syn_stp.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/exp2syn_stp.c
Translating can_mig.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/can_mig.c
Translating gap.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/gap.c
Thread Safe
Thread Safe
Thread Safe
Translating h_kole.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/h_kole.c
Translating imCA3.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/imCA3.c
Translating k.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/k.c
Thread Safe
Thread Safe
Thread Safe
Translating kBK.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/kBK.c
Translating kdmc_BS.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/kdmc_BS.c
Translating kap_BS.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/kap_BS.c
Thread Safe
Thread Safe
Thread Safe
Translating kdrCA3.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/kdrCA3.c
Translating kdr_BS.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/kdr_BS.c
Translating kdrinter.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/kdrinter.c
Thread Safe
Thread Safe
Thread Safe
Translating leak.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/leak.c
Translating nainter.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/nainter.c
Translating na.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/na.c
Thread Safe
Thread Safe
Thread Safe
Translating nax_BS.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/nax_BS.c
Translating napCA3.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/napCA3.c
Translating natCA3.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/natCA3.c
Thread Safe
Thread Safe
Thread Safe
Translating vecevent_coreneuron.mod into /Users/gregglickert/.Trash/single_cell 16-27-02-218/modfiles/arm64/vecevent_coreneuron.c
Thread Safe
AMPA_NMDA_STP.cCaDynamics.c::4242::1818:: warning: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
42 | 42e | x t eerxnt edronu bdloeu b*lgee t*agregt(a)r;g
( )| ; ^
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h::1715:: 17note: :expanded from macro 'getarg'
note: expanded from macro 'getarg'
15 | #15d | e#fdienfei ngee tgaertga r gh o ch_ogce_tgaertga
r g|
^
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h49::4916::16 :note: conflicting prototype is herenote:
conflicting prototype is here
49 | ex t49e | rextern double*n getarg(int) ;d
o u| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15ble* getarg(int);
:17: | note: expanded from macro 'getarg'
^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h15: | 15#:d17efine ge:t anote: rexpanded from macro 'getarg'g
hoc_ g15e | t#adregf
i n| e ^
getarg hoc_getarg
| ^
AMPA_NMDA_STP.c:414:32: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
414 | if (_tsav > t){ extern char* hoc_object_name(); hoc_execerror(hoc_object_name(_pnt->ob), ":Event arrived out of order. Must call ParallelContext.set_maxstep AFTER assigning minimum NetCon.delay");}
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:46:14: note: conflicting prototype is here
46 | extern char* hoc_object_name(Object*);
| ^
Ca_HVA.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
1 warning generated.
1 warning generated.
2 warnings generated.
Ca_LVA.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
Gfluct.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
GABA_A_STP.c:42:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
42 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
GABA_A_STP.c:356:32: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
356 | if (_tsav > t){ extern char* hoc_object_name(); hoc_execerror(hoc_object_name(_pnt->ob), ":Event arrived out of order. Must call ParallelContext.set_maxstep AFTER assigning minimum NetCon.delay");}
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:46:14: note: conflicting prototype is here
46 | extern char* hoc_object_name(Object*);
| ^
Ih.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
1 warning generated.
1 warning generated.
1 warning generated.
2 warnings generated.
K_T.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
Im.c:/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:43:1849:: 16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | /Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'extern d
oub le *getarg();
| 15 | #defi ^
ne getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: Im_v2.c:note: 43expanded from macro 'getarg'
:18: 15 | #define getwarning: ara function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]g
hoc_getarg
| ^
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
K_P.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
1 warning generated.
1 warning generated.
1 warning generated.
1 warning generated.
Kv3_1.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
Kd.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
NaTa.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #defineKv2like.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]g
etarg hoc_getarg
| ^
43 | /Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49 :e16xte:r nnote: conflicting prototype is here
49 | extern do uble* getargd(iont);
uble *getarg(); | ^
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getar/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.hg:15:17: note: expanded from macro 'getarg'
15 hoc_getarg
| #| d ^e
fine getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
1 warning generated.
1 warning generated.
1 warning generated.
1 warning generated.
NaTs.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extNaV.cern doub:l43e: 18*:g ewarning: ta function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]a
rg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
4315 | | # deexftienren double ge*tgetarg(a)r;g
| h ^o
c_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h :1549 | :16: note: conflicting prototype is here
#define ge t49a | externr gd hoc_goetuarble* getag
r| g ^
(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getar/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: g note: hconflicting prototype is hereo
c_getarg
| ^
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
Nap.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
SK.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
NaV.c:404:17: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
404 | extern double *_getelm();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/nrniv_mf.h:26:16: note: conflicting prototype is here
26 | extern double* _getelm(int, int);
| ^
1 warning generated.
1 warning generated.
1 warning generated.
cal2.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
can_mig.c:43:18: /Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.hwarning: :a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]15
:17: note: expanded from macro 'getarg'
cadad.c:42:1815: | #warning: da function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]e
43 | extefrinn ed o42u | b l eegxettear n* gdeotragr g (u)b;l
e | * ^g
hoc_geteatragr
g (| ) ^;
| /Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: ^
note: expanded from macro 'getarg'
15 | #de/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h
:15: 1749: | enote: xexpanded from macro 'getarg't
ern d15o | u#bdleeff*i ngeetarg(i ngte)t;a
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: inote: expanded from macro 'getarg'
ne r getg15a | h#rdefine go c _hoc_ggetarg
| etargge ^ thaoc
rg
| ^
_/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.hg:etarg
| 49/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h: ^:49:16:
16: note: conflicting prototype is here
note: conflicting prototype is here
49 | exte 49 | exrtern nd oduble*o ugbetargl(ei*n tgetarg);
| ^
(int/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h);:
15 | : ^17:
note: expanded from macro 'getarg'
15 | #de/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.hf:15i:n17e: note: gexpanded from macro 'getarg'
etarg 15 | #de fhine geotc_geatarg
| ^
rg hoc_getarg
| ^
1 warning generated.
-> Compiling Im.c -> Compiling Im_v2.c -> Compiling K_P.c -> Compiling K_T.c -> Compiling Kv2like.c -> Compiling Kd.c -> Compiling Kv3_1.c -> Compiling NaTa.c -> Compiling NaV.c -> Compiling NaTs.c -> Compiling Nap.c -> Compiling SK.c -> Compiling can_mig.c -> Compiling cadad.c -> Compiling cal2.c -> Compiling exp2syn_stp.c -> Compiling gap.c -> Compiling h_kole.c -> Compiling imCA3.c
1 warning generated.
1 warning generated.
2 warnings generated.
exp2syn_stp.c:42:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
42 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
exp2syn_stp.c:343:32: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
343 | if (_tsav > t){ extern char* hoc_object_name(); hoc_execerror(hoc_object_name(_pnt->ob), ":Event arrived out of order. Must call ParallelContext.set_maxstep AFTER assigning minimum NetCon.delay");}
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:46:14: note: conflicting prototype is here
46 | extern char* hoc_object_name(Object*);
| ^
h_kole.c:42:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
42 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
gap.c:41:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
41 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
imCA3.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
1 warning generated.
2 warnings generated.
1 warning generated.
1 warning generated.
kBK.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();k.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:
49:16 :| ^
note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
kap_BS.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
kdmc_BS.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
1 warning generated.
1 warning generated.
1 warning generated.
1 warning generated.
kdrCA3.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
kdr_BS.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
kdrinter.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
leak.c:41:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
41 | extern double *getarg();
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
1 warning generated.
1 warning generated.
1 warning generated.
1 warning generated.
natCA3.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
nainter.c/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | :#def43ine get:a18r:g warning: ha function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]na.c
:oc_getar43g:
18 :| ^warning:
a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | /Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h :e49x:t16e:r nnote: conflicting prototype is hered
ouble 4943 | | *extergne double* getargt(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: argnote: expanded from macro 'getarg'
() ;
napCA3.c15 | ^e | :#xd44
:t18:/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h :warning: er15n: 17d:o unote: blea function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype] *g
expanded from macro 'getarg'e
e t15a | r#gd(efine get fine gearg 44 | )h;
otca_rgge t ahro cg_
getarg
| ^
extern| d ^o
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.hu:bl49e:16 :* genote: tconflicting prototype is here
49 | extern douablrg();/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17:
| ^
e* getarg(int);
note: | ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15expanded from macro 'getarg':17/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:: note: expanded from macro 'getarg'
1515 | :#17d:e fnote: iexpanded from macro 'getarg'n
e
ge 15 | #d15tefine a | rg# getargdef i hhoc_nogce_targ
| ^
getarg
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
49e | ^
getarg ho | ex/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.hterc:49:16: note: conflicting prototype is here
49 | e_getanr double* ggetarg(int);
| x ^t
ern do/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.hu:
b 15:17: note: expanded from macro 'getarg'l
15 | #define getarg hoc_getarg
| ^
e* ge| targ(in ^t
);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
1 warning generated.
1 warning generated.
1 warning generated.
1 warning generated.
-> Compiling k.c -> Compiling kBK.c -> Compiling kap_BS.c -> Compiling kdmc_BS.c -> Compiling kdrCA3.c -> Compiling kdr_BS.c -> Compiling kdrinter.c -> Compiling leak.c -> Compiling na.c -> Compiling nainter.c -> Compiling napCA3.c -> Compiling natCA3.c -> Compiling nax_BS.c -> Compiling vecevent_coreneuron.c => LINKING shared library ./libnrnmech.dylib
nax_BS.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
43 | extern double *getarg();
| ^
vecevent_coreneuron.c:43:18: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #def i43n | e geexttaerrgn dhooucb_lgee t*agregt
a r| g ^(
);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:49:16: note: conflicting prototype is here
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h49: | 15e:x17t:e rnote: nexpanded from macro 'getarg'
dou 15 | #deble* gfeitnaer gg(eitnatr)g;
h| o ^c
_ge/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17t:a rnote: gexpanded from macro 'getarg'
| ^
15 | #define getarg hoc_ge/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.ht:a49r:g16
: | note: ^conflicting prototype is here
49 | extern double* getarg(int);
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/hocdec.h:15:17: note: expanded from macro 'getarg'
15 | #define getarg hoc_getarg
| ^
vecevent_coreneuron.c:242:32: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C23, conflicting with a previous declaration [-Wdeprecated-non-prototype]
242 | if (_tsav > t){ extern char* hoc_object_name(); hoc_execerror(hoc_object_name(_pnt->ob), ":Event arrived out of order. Must call ParallelContext.set_maxstep AFTER assigning minimum NetCon.delay");}
| ^
/Users/gregglickert/miniconda3/envs/bmtk/lib/python3.11/site-packages/neuron/.data/include/oc_ansi.h:46:14: note: conflicting prototype is here
46 | extern char* hoc_object_name(Object*);
| ^
2 warnings generated.
1 warning generated.
=> LINKING executable ./special LDFLAGS are:
Successfully created arm64/special
ld: warning: ignoring duplicate libraries: '-lnrnmech'
Part 2: Cell Loading Methods¶
bmtool supports three different approaches to load neuron models. Each method returns a cell creator that can be used with any analysis function.
2.1: Loading Allen Database Cells¶
Download and load a realistic neuron model from the Allen Institute Brain Observatory.
# Method 1: Allen Database Cell
# this downloads from allen database which is already done
# from allensdk.api.queries.biophysical_api import BiophysicalApi
# # Download cell model from Allen
# bp = BiophysicalApi()
# bp.cache_stimulus = False
# neuronal_model_id = 472451419 # Example: Layer 5 Pyramidal Cell
# bp.cache_data(neuronal_model_id)
dynamic_params = "386049446_fit.json"
morphology = "Nr5a1-Cre_Ai14-177334.05.01.01_491459171_m.swc"
# Create Allen cell loader
cell1 = load_allen_database_cells(
morphology=morphology,
dynamic_params=dynamic_params,
model_processing='aibs_allactive'
)
profiler = Profiler(template_dir='.', mechanism_dir='modfiles', dt=0.05)
Mechanisms already loaded from path: modfiles. Aborting.
It is important to note the order in which we are doing things for loading the Allen database cell. You need to first load the cell, but do not call the class. Then load the mod files(here done with the profiler to also get our template setup for the cell2) and then initalize cell1.
cell1 = cell1()
2.2: Loading NEURON HOC Template Cells¶
Use pre-defined HOC template files for standard neuronal models.
# Method 2: NEURON HOC Template
# The template is loaded by passing the template name as a string
cell2 = 'CP_Cell' # Change this to match your template name
2.3: Loading Python Class-Based Cells¶
Define and use custom neuron models programmatically using Python classes.
# Method 3: Python Class-Based Cell
h.load_file("stdrun.hoc")
class SimpleSoma(object):
"""Single-section cell: A soma with leak, sodium, and potassium channels."""
def __init__(self):
self.create_sections()
self.build_topology()
self.build_subsets()
self.define_geometry()
self.define_biophysics()
#
def create_sections(self):
"""Create the sections of the cell."""
# NOTE: cell=self is required to tell NEURON of this object.
self.soma = h.Section(name='soma', cell=self)
#
def build_topology(self):
"""Connect the sections of the cell to build a tree."""
# Single section - no connections needed
pass
#
def define_geometry(self):
"""Set the 3D geometry of the cell."""
self.soma.L = 500 # soma length um
self.soma.diam = 500 # soma diameter um
h.define_shape() # Translate into 3D points.
#
def define_biophysics(self):
"""Assign the membrane properties across the cell."""
for sec in self.all: # 'all' defined in build_subsets
sec.cm = 1 # membrane capacitance uF/cm2
sec.Ra = 30 # ohm-cm
# Insert leak channel
self.soma.insert('leak') # Leak channel
self.soma.glbar_leak = 0.0003 # S/cm2
self.soma.el_leak = -60 # mV
# Insert sodium channel
self.soma.insert('na') # Sodium channel
self.soma.gnabar_na = 0.22 # S/cm2
self.soma.nao = 79.8 # extracellular Na concentration
# Insert potassium channel
self.soma.insert('k') # Potassium channel
self.soma.gkbar_k = 0.036 # S/cm2
self.soma.ki = 69.35 # intracellular K concentration
#
def build_subsets(self):
"""Build subset lists. For now we define 'all'."""
self.all = h.SectionList()
self.all.wholetree(sec=self.soma)
cell3 = SimpleSoma()
Part 3: Analysis Methods¶
Now we demonstrate all available analysis techniques. These methods work with any of the cell loading approaches above.
Setup Analysis Parameters¶
Define comprehensive settings for each analysis method.
# Analysis settings dictionary
# These parameters can be tuned based on your specific cell type and experimental constraints
analysis_settings = {
'Passive': {
'celsius': 26.0,
'kwargs': {
'inj_amp': -50.0,
'inj_delay': 1500.0,
'inj_dur': 1000.0,
'tstop': 2500.0,
'method': 'exp2' # options: 'exp2', 'exp', 'simple'
}
},
'CurrentClamp': {
'celsius': 34.0,
'kwargs': {
'inj_amp': 130.0,
'inj_delay': 1500.0,
'inj_dur': 1000.0,
'tstop': 3000.0,
'threshold': -15.0
}
},
'ZAP': {
'celsius': 34.0,
'kwargs': {
'inj_amp': 100.0,
'inj_delay': 1000.0,
'inj_dur': 15000.0,
'tstop': 15500.0,
'fstart': 0.0,
'fend': 15.0,
'chirp_type': 'linear'
}
},
'FI': {
'celsius': 34.0,
'kwargs': {
'i_start': 0.0,
'i_stop': 2000.0,
'i_increment': 100.0,
'tstart': 1500.0
}
}
}
Helper Functions for FI Curve Analysis¶
Define utility functions for analyzing frequency-current relationships.
def find_slope(X, Y):
"""Find the slope and intercept using least squares regression."""
A = np.vstack([X, np.ones_like(X)]).T
m, c = np.linalg.lstsq(A, Y, rcond=None)[0]
return m, c
def fit_slope_to_max_y(X, Y):
"""Fit a line from first spike to maximum spike frequency.
This captures the linear region of the FI curve where the relationship
is most pronounced.
"""
# Find where Y > 0
positive_data = Y > 0
X_positive = X[positive_data]
Y_positive = Y[positive_data]
if len(Y_positive) == 0:
return None, None, X, Y
# Find the index of the maximum Y value
max_idx = np.argmax(Y_positive)
# Only use data from first spike to max
X_fit = X_positive[:max_idx + 1]
Y_fit = Y_positive[:max_idx + 1]
m, c = find_slope(X_fit, Y_fit)
return m, c, X_fit, Y_fit
def find_rheobase(X, Y):
"""Find the rheobase: minimum current required to evoke a spike."""
non_zero_indices = np.nonzero(Y)[0]
if len(non_zero_indices) > 0:
rheobase = X[non_zero_indices[0]]
return rheobase
return None
3.1: Passive Properties Analysis¶
Analyze membrane properties under hyperpolarizing current injection.
proc_settings = analysis_settings['Passive']
h.celsius = proc_settings['celsius']
sim_passive = Passive(cell1, **proc_settings['kwargs'])
X_passive, Y_passive = run_and_plot(
sim_passive,
title='Passive Membrane Properties',
xlabel='Time (ms)',
ylabel='Membrane Potential (mV)',
plot_injection_only=True
)
# Add exponential fit
if sim_passive.method == 'exp2':
plt.gca().plot(*sim_passive.double_exponential_fit(), 'r:', linewidth=2, label='Double exponential fit')
plt.legend()
elif sim_passive.method == 'exp':
plt.gca().plot(*sim_passive.single_exponential_fit(), 'r:', linewidth=2, label='Single exponential fit')
plt.legend()
plt.tight_layout()
plt.show()
Injection location: Biophys1[1].soma[0](0.5) Recording: Biophys1[1].soma[0](0.5)._ref_v Running simulation for passive properties... V Rest: -99.70 (mV) Resistance: 362.19 (MOhms) Membrane time constant: 54.19 (ms) V_rest Calculation: Voltage taken at time 1500.0 (ms) is -99.70 (mV) R_in Calculation: dV/dI = (v_final-v_rest)/(i_final-i_start) (-117.81 - (-99.70)) / (-0.05 - 0) 18.11 (mV) / 0.05 (nA) = 362.19 (MOhms) Tau Calculation: Fit a double exponential curve to the membrane potential response f(t) = a0 + a1*exp(-t/tau1) + a2*exp(-t/tau2) Constrained by initial value: f(0) = a0 + a1 + a2 = v_rest Fit parameters: (a0, a1, a2, tau1, tau2) = (-117.80, 14.49, 3.61, 54.19, 2.77) Membrane time constant is determined from the slowest exponential term: 54.19 (ms) Sag potential: v_sag = v_peak - v_final = 0.00 (mV) Normalized sag potential: v_sag / (v_peak - v_rest) = -0.000
3.2: Current Clamp Analysis¶
Measure voltage response to current injection - fundamental for understanding cell excitability.
proc_settings = analysis_settings['CurrentClamp']
h.celsius = proc_settings['celsius']
sim_cc = CurrentClamp(cell3, **proc_settings['kwargs'])
X_cc, Y_cc = run_and_plot(
sim_cc,
title='Current Clamp Response',
xlabel='Time (ms)',
ylabel='Membrane Potential (mV)',
plot_injection_only=True
)
plt.tight_layout()
plt.show()
Injection location: <__main__.SimpleSoma object at 0x14d5cc510>.soma(0.5) Recording: <__main__.SimpleSoma object at 0x14d5cc510>.soma(0.5)._ref_v Current clamp simulation running... Number of spikes: 179
3.3: Impedance Amplitude Profile (ZAP)¶
Analyze frequency response using a chirp stimulus to measure impedance at different frequencies.
proc_settings = analysis_settings['ZAP']
h.celsius = proc_settings['celsius']
sim_zap = ZAP(cell2, **proc_settings['kwargs'])
# Plot voltage response
X_zap, Y_zap = run_and_plot(
sim_zap,
title='ZAP Voltage Response',
xlabel='Time (ms)',
ylabel='Membrane Potential (mV)',
plot_injection_only=True
)
plt.tight_layout()
plt.show()
# Plot ZAP current stimulus
plt.figure(figsize=(10, 4))
plt.plot(X_zap, sim_zap.zap_vec)
plt.title('ZAP Current Stimulus (Linear Chirp)')
plt.xlabel('Time (ms)')
plt.ylabel('Current Injection (nA)')
plt.tight_layout()
plt.show()
# Plot impedance profile
plt.figure(figsize=(10, 4))
freq, imp = sim_zap.get_impedance(smooth=9)
plt.plot(freq, imp, linewidth=2)
plt.title('Impedance Amplitude Profile')
plt.xlabel('Frequency (Hz)')
plt.ylabel('Impedance (MOhms)')
plt.grid(True, alpha=0.3)
plt.tight_layout()
plt.show()
# Find resonant frequency
if len(freq) > 0:
max_imp_idx = np.argmax(imp)
resonant_freq = freq[max_imp_idx]
max_imp = imp[max_imp_idx]
print(f"Resonant frequency: {resonant_freq:.2f} Hz")
print(f"Maximum impedance: {max_imp:.2f} MOhms")
Injection location: CP_Cell[2].soma[0](0.5) Recording: CP_Cell[2].soma[0](0.5)._ref_v ZAP current simulation running... Chirp current injection with frequency changing from 0 to 15 Hz over 15 seconds Impedance is calculated as the ratio of FFT amplitude of membrane voltage to FFT amplitude of chirp current
Resonant Peak Frequency: 0.333 (Hz)
Resonant frequency: 0.33 Hz Maximum impedance: 84.45 MOhms
3.4: Frequency-Intensity (FI) Curve Analysis¶
Measure the relationship between injected current and spike frequency
proc_settings = analysis_settings['FI']
h.celsius = proc_settings['celsius']
sim_fi = FI(cell2, **proc_settings['kwargs'])
X_fi, Y_fi = run_and_plot(
sim_fi,
title='Frequency-Intensity Curve',
xlabel='Injection Current (nA)',
ylabel='Spike Frequency (Hz)'
)
plt.tight_layout()
plt.show()
Injection location: CP_Cell[3].soma[0](0.5)
Recording: CP_Cell[3].soma[0](0.5)._ref_v
Running simulations for FI curve...
Results
Injection (pA): number of spikes
0 0.0 0
1 100.0 0
2 200.0 15
3 300.0 23
4 400.0 31
5 500.0 40
6 600.0 49
7 700.0 59
8 800.0 70
9 900.0 4
10 1000.0 2
11 1100.0 2
12 1200.0 2
13 1300.0 2
14 1400.0 2
15 1500.0 1
16 1600.0 1
17 1700.0 1
18 1800.0 1
19 1900.0 1
FI Curve Post-Processing and Analysis¶
# Fit linear portion of FI curve
m, c, X_fit, Y_fit = fit_slope_to_max_y(X_fi, Y_fi)
# Find rheobase
rheobase = find_rheobase(X_fi, Y_fi)
print(f" Rheobase (minimum current for firing): {rheobase:.1f} pA")
Rheobase (minimum current for firing): 200.0 pA