Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions gui_tut1/index.npjson
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"simConfig_python": "src/cfg.py",
"netParams_python": "src/netParams.py"
}
16 changes: 16 additions & 0 deletions gui_tut1/src/cfg.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
from netpyne import specs

# Simulation options
cfg = specs.SimConfig() # object of class SimConfig to store simulation configuration

cfg.duration = 0.2*1e3 # Duration of the simulation, in ms
cfg.dt = 0.1 # Internal integration timestep to use
cfg.verbose = False # Show detailed messages
cfg.recordTraces = {'V_soma':{'sec':'soma','loc':0.5,'var':'v'},
'V_dend': {'sec': 'dend', 'loc': 1.0, 'var':'v'}} # Dict with traces to record
cfg.recordCells = [0]
cfg.recordStep = 0.1 # Step size in ms to save data (eg. V traces, LFP, etc)
cfg.filename = 'gui_tut1' # Set file output name
cfg.saveJson = False # Save params, network and sim output to pickle file
cfg.analysis['iplotTraces'] = {'include': [0], 'overlay': True}
cfg.analysis['iplotRaster'] = {'markerSize': 5, 'showFig': True}
23 changes: 0 additions & 23 deletions gui_tut1.py → gui_tut1/src/netParams.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,26 +37,3 @@
'delay': 5, # delay min=0.2, mean=13.0, var = 1.4
'synMech': 'exc',
'sec': 'dend'}

# Simulation options
simConfig = specs.SimConfig() # object of class SimConfig to store simulation configuration

simConfig.duration = 0.2*1e3 # Duration of the simulation, in ms
simConfig.dt = 0.1 # Internal integration timestep to use
simConfig.verbose = False # Show detailed messages
simConfig.recordTraces = {'V_soma':{'sec':'soma','loc':0.5,'var':'v'},
'V_dend': {'sec': 'dend', 'loc': 1.0, 'var':'v'}} # Dict with traces to record
simConfig.recordCells = [0]
simConfig.recordStep = 0.1 # Step size in ms to save data (eg. V traces, LFP, etc)
simConfig.filename = 'gui_tut1' # Set file output name
simConfig.saveJson = False # Save params, network and sim output to pickle file
simConfig.analysis['iplotTraces'] = {'include': [0], 'overlay': True}
simConfig.analysis['iplotRaster'] = {'markerSize': 5, 'showFig': True}


if __name__ == '__main__':
netpyne_geppetto.netParams=netParams
netpyne_geppetto.simConfig=simConfig

#from netpyne import sim
#sim.createSimulateAnalyze(netParams, simConfig)
File renamed without changes.
File renamed without changes.
5 changes: 5 additions & 0 deletions gui_tut2/index.npjson
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"mod_folder": "../mod",
"simConfig_python": "src/cfg.py",
"netParams_python": "src/netParams.py"
}
16 changes: 16 additions & 0 deletions gui_tut2/src/cfg.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
from netpyne import specs

# Simulation options
cfg = specs.SimConfig() # object of class SimConfig to store simulation configuration

cfg.duration = 0.5*1e3 # Duration of the simulation, in ms
cfg.dt = 0.1 # Internal integration timestep to use
cfg.hParams['celsius'] = 34
cfg.verbose = False # Show detailed messages
cfg.recordTraces = {'V_soma':{'sec':'soma','loc':0.5,'var':'v'}} # Dict with traces to record
cfg.recordStep = 0.1 # Step size in ms to save data (eg. V traces, LFP, etc)
cfg.filename = 'model_output' # Set file output name
cfg.savePickle = False # Save params, network and sim output to pickle file

cfg.analysis['iplotRaster'] = {'markerSize': 5, 'showFig': True}
cfg.analysis['iplotTraces'] = {'include': [0,2], 'oneFigPer': 'trace'}
24 changes: 0 additions & 24 deletions gui_tut2.py → gui_tut2/src/netParams.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,27 +43,3 @@
'delay': 5,
'synMech': 'GABA',
'sec': 'soma'}


# Simulation options
simConfig = specs.SimConfig() # object of class SimConfig to store simulation configuration

simConfig.duration = 0.5*1e3 # Duration of the simulation, in ms
simConfig.dt = 0.1 # Internal integration timestep to use
simConfig.hParams['celsius'] = 34
simConfig.verbose = False # Show detailed messages
simConfig.recordTraces = {'V_soma':{'sec':'soma','loc':0.5,'var':'v'}} # Dict with traces to record
simConfig.recordStep = 0.1 # Step size in ms to save data (eg. V traces, LFP, etc)
simConfig.filename = 'model_output' # Set file output name
simConfig.savePickle = False # Save params, network and sim output to pickle file

simConfig.analysis['iplotRaster'] = {'markerSize': 5, 'showFig': True}
simConfig.analysis['iplotTraces'] = {'include': [0,2], 'oneFigPer': 'trace'}

if __name__ == '__main__':
netpyne_geppetto.netParams=netParams
netpyne_geppetto.simConfig=simConfig


#from netpyne import sim
#sim.createSimulateAnalyze(netParams, simConfig)
File renamed without changes.
File renamed without changes.
File renamed without changes.
5 changes: 5 additions & 0 deletions gui_tut3/index.npjson
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"mod_folder": "../mod",
"simConfig_python": "src/cfg.py",
"netParams_python": "src/netParams.py"
}
31 changes: 31 additions & 0 deletions gui_tut3/src/cfg.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
from netpyne import specs
from src.netParams import netParams

#------------------------------------------------------------------------------
#
# SIMULATION CONFIGURATION
#
#------------------------------------------------------------------------------

# Run parameters
cfg = specs.SimConfig() # object of class simConfig to store simulation configuration
cfg.duration = 1.0*1e3 # Duration of the simulation, in ms
cfg.hParams['v_init'] = -65 # set v_init to -65 mV
cfg.dt = 0.1 # Internal integration timestep to use
cfg.verbose = False # Show detailed messages
cfg.recordStep = 1 # Step size in ms to save data (eg. V traces, LFP, etc)
cfg.filename = 'rxd_net' # Set file output name


# Recording/plotting parameters
cfg.recordTraces = {'V_soma':{'sec': 'soma','loc': 0.5,'var': 'v'},
'ik_soma': {'sec': 'soma', 'loc': 0.5, 'var': 'ik'},
'cai_soma': {'sec': 'soma', 'loc':0.5, 'var': 'cai'},
'cao_soma': {'sec': 'soma', 'loc': 0.5, 'var': 'cao'}}

cfg.recordLFP = [[-15, y, 1.0*netParams.sizeZ] for y in range(int(netParams.sizeY/3), int(netParams.sizeY), int(netParams.sizeY/3))]

cfg.analysis['iplotTraces'] ={'include': [0]}
cfg.analysis['iplotRaster'] = {'orderBy': 'y', 'orderInverse': True, 'saveFig': True, 'figSize': (9,3)} # Plot a raster
cfg.analysis['iplotLFP'] = {'includeAxon': False, 'figSize': (6,10), 'saveFig': True}
cfg.analysis['iplotRxDConcentration'] = {'speciesLabel': 'ca', 'regionLabel': 'ecs'}
44 changes: 0 additions & 44 deletions gui_tut3.py → gui_tut3/src/netParams.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,47 +121,3 @@

### rates
netParams.rxdParams['rates'] = {'ip3rg': {'species': h_gate, 'rate': '(1. / (1 + 1000. * ca[cyt] / (0.3)) - %s) / ip3rtau'%(h_gate)}}




#------------------------------------------------------------------------------
#
# SIMULATION CONFIGURATION
#
#------------------------------------------------------------------------------

# Run parameters
simConfig = specs.SimConfig() # object of class simConfig to store simulation configuration
simConfig.duration = 1.0*1e3 # Duration of the simulation, in ms
simConfig.hParams['v_init'] = -65 # set v_init to -65 mV
simConfig.dt = 0.1 # Internal integration timestep to use
simConfig.verbose = False # Show detailed messages
simConfig.recordStep = 1 # Step size in ms to save data (eg. V traces, LFP, etc)
simConfig.filename = 'rxd_net' # Set file output name


# Recording/plotting parameters
simConfig.recordTraces = {'V_soma':{'sec': 'soma','loc': 0.5,'var': 'v'},
'ik_soma': {'sec': 'soma', 'loc': 0.5, 'var': 'ik'},
'cai_soma': {'sec': 'soma', 'loc':0.5, 'var': 'cai'},
'cao_soma': {'sec': 'soma', 'loc': 0.5, 'var': 'cao'}}

simConfig.recordLFP = [[-15, y, 1.0*netParams.sizeZ] for y in range(int(netParams.sizeY/3), int(netParams.sizeY), int(netParams.sizeY/3))]

simConfig.analysis['iplotTraces'] ={'include': [0]}
simConfig.analysis['iplotRaster'] = {'orderBy': 'y', 'orderInverse': True, 'saveFig': True, 'figSize': (9,3)} # Plot a raster
simConfig.analysis['iplotLFP'] = {'includeAxon': False, 'figSize': (6,10), 'saveFig': True}
simConfig.analysis['iplotRxDConcentration'] = {'speciesLabel': 'ca', 'regionLabel': 'ecs'}



# ------------------------------------------------------------
# Run sim
# ------------------------------------------------------------
if __name__ == '__main__':
netpyne_geppetto.netParams=netParams
netpyne_geppetto.simConfig=simConfig

#from netpyne import sim
#sim.createSimulateAnalyze(netParams, simConfig)
Loading