forked from ModelDBRepository/262670
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #7 from sanjayankur31/neuroml-ankur
Complete conversion of KC cell
- Loading branch information
Showing
24 changed files
with
484 additions
and
104 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,12 @@ | ||
*.dat | ||
x86_64/ | ||
channels/*dat | ||
NeuroML2/channels/LEMS* | ||
NeuroML2/channels/*mod | ||
NeuroML2/*mod | ||
NeuroML2/*.hoc | ||
NeuroML2/*.dat | ||
NeuroML2/*_nrn.py | ||
NeuroML2/*.spikes | ||
.mypy_cache/ | ||
*.npy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/bin/bash | ||
|
||
# Copyright 2024 Ankur Sinha | ||
# Author: Ankur Sinha <sanjay DOT ankur AT gmail DOT com> | ||
# File : | ||
# | ||
|
||
if [[ -z "${MODEL_DIR}" ]]; then | ||
export MODEL_DIR=$(pwd) | ||
echo "Setting model root directory to $MODEL_DIR" | ||
echo "To use a custom path, set the MODEL_DIR environment variable to the desired path." | ||
fi | ||
|
||
export PYTHONPATH="${MODEL_DIR}/mb:${MODEL_DIR}/nrn:${MODEL_DIR}/morphutils:${MODEL_DIR}/common" | ||
nrnivmodl ./mb/mod/ | ||
python ./mb/test_cell/test_kc.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
target: LEMS_KC_step_test.xml | ||
engine: jNeuroML_NEURON | ||
mep: .test.kc.mep | ||
experiments: | ||
stepKC: | ||
observables: | ||
spike times: | ||
file: | ||
path: KC_step_test.KC_pop.v.dat | ||
columns: [0,1] | ||
scaling: [1000,1000] | ||
spike detection: | ||
method: threshold | ||
threshold: -10. | ||
tolerance: 0.005087969567027844 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
system: Testing a detailed cell | ||
|
||
experiments: | ||
stepKC: | ||
expected: | ||
spike times: [144.45000000000556, 177.64999999997536, 210.29999999994567, 242.74999999991616, 275.0499999998868, 307.19999999985754, 339.2249999998284, 371.07499999979945, 402.74999999977064, 434.1499999997421, 465.2249999997138, 495.87499999968594, 525.9749999997221, 555.3499999998289, 583.8499999999326] | ||
|
||
# generated from test-kc.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<neuroml xmlns="http://www.neuroml.org/schema/neuroml2" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.neuroml.org/schema/neuroml2 https://raw.github.com/NeuroML/NeuroML2/development/Schemas/NeuroML2/NeuroML_v2.3.xsd" id="KC_doc"> | ||
<include href="channels/pas.channel.nml"/> | ||
<include href="channels/kv.channel.nml"/> | ||
<include href="channels/ka.channel.nml"/> | ||
<include href="channels/kst.channel.nml"/> | ||
<include href="channels/naf.channel.nml"/> | ||
<include href="channels/nas.channel.nml"/> | ||
<cell id="KC"> | ||
<morphology id="morphology"> | ||
<segment id="0" name="Seg0"> | ||
<proximal x="0.0" y="0.0" z="0.0" diameter="20.0"/> | ||
<distal x="0.0" y="0.0" z="6.366" diameter="20.0"/> | ||
</segment> | ||
<segmentGroup id="soma_group" neuroLexId="GO:0043025"> | ||
<notes>Default soma segment group for the cell</notes> | ||
<member segment="0"/> | ||
</segmentGroup> | ||
<segmentGroup id="all"> | ||
<notes>Default segment group for all segments in the cell</notes> | ||
<member segment="0"/> | ||
</segmentGroup> | ||
</morphology> | ||
<biophysicalProperties id="biophys"> | ||
<membraneProperties> | ||
<channelDensity id="pas" ionChannel="pas" condDensity="9.75e-5 S_per_cm2" erev="-70 mV" ion="non_specific"/> | ||
<channelDensity id="kv" ionChannel="kv" condDensity="1.5e-3 S_per_cm2" erev="-81 mV" ion="k"/> | ||
<channelDensity id="ka" ionChannel="ka" condDensity="1.4525e-2 S_per_cm2" erev="-81 mV" ion="k"/> | ||
<channelDensity id="kst" ionChannel="kst" condDensity="2.0275e-3 S_per_cm2" erev="-81 mV" ion="k"/> | ||
<channelDensity id="naf" ionChannel="naf" condDensity="3.5e-2 S_per_cm2" erev="58 mV" ion="na"/> | ||
<channelDensity id="nas" ionChannel="nas" condDensity="3e-3 S_per_cm2" erev="58 mV" ion="na"/> | ||
<spikeThresh value="-10mV"/> | ||
<specificCapacitance value="1 uF_per_cm2"/> | ||
<initMembPotential value="-70mV"/> | ||
</membraneProperties> | ||
<intracellularProperties> | ||
<resistivity value="35.4 ohm_cm"/> | ||
</intracellularProperties> | ||
</biophysicalProperties> | ||
</cell> | ||
<pulseGenerator id="pg" delay="100ms" duration="500ms" amplitude="16pA"/> | ||
<network id="KC_net"> | ||
<population id="KC_pop" component="KC" size="1"/> | ||
<inputList id="input_list" population="KC_pop" component="pg"> | ||
<input id="0" target="../KC_pop[0]" destination="synapses" segmentId="0"/> | ||
</inputList> | ||
</network> | ||
</neuroml> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
<Lems> | ||
|
||
<!-- | ||
This LEMS file has been automatically generated using PyNeuroML v1.2.8 (libNeuroML v0.5.9) | ||
--> | ||
|
||
<!-- Specify which component to run --> | ||
<Target component="KC_step_test"/> | ||
|
||
<!-- Include core NeuroML2 ComponentType definitions --> | ||
<Include file="Cells.xml"/> | ||
<Include file="Networks.xml"/> | ||
<Include file="Simulation.xml"/> | ||
|
||
<Include file="KC.net.nml"/> | ||
<Include file="channels/pas.channel.nml"/> | ||
<Include file="channels/kv.channel.nml"/> | ||
<Include file="RaySigmoid.nml"/> | ||
<Include file="channels/ka.channel.nml"/> | ||
<Include file="channels/kst.channel.nml"/> | ||
<Include file="channels/naf.channel.nml"/> | ||
<Include file="channels/nas.channel.nml"/> | ||
|
||
<Simulation id="KC_step_test" length="700.0ms" step="0.01ms" target="KC_net" seed="12345"> <!-- Note seed: ensures same random numbers used every run --> | ||
<Display id="DispPop__KC_pop" title="Membrane potentials of cells in KC_pop" timeScale="1ms" xmin="-70.0" xmax="770.0000000000001" ymin="-90" ymax="50"> | ||
<Line id="KC_pop[0]: v" quantity="KC_pop[0]/v" scale="1mV" color="#d54f33" timeScale="1ms"/> | ||
</Display> | ||
|
||
<OutputFile id="Volts_file__KC_pop" fileName="KC_step_test.KC_pop.v.dat"> | ||
<OutputColumn id="v_KC_pop_0__v" quantity="KC_pop[0]/v"/> | ||
</OutputFile> | ||
|
||
<OutputFile id="k_dat" fileName="k.dat"> | ||
<OutputColumn id="KC_pop_0__biophys_membraneProperties_kv_iDensity" quantity="KC_pop[0]/biophys/membraneProperties/kv/iDensity"/> | ||
</OutputFile> | ||
|
||
<EventOutputFile id="Spikes_file__KC_pop" fileName="KC_step_test.KC_pop.spikes" format="ID_TIME"> | ||
<EventSelection id="0" select="KC_pop[0]" eventPort="spike"/> | ||
</EventOutputFile> | ||
|
||
</Simulation> | ||
|
||
</Lems> |
Oops, something went wrong.