my_model_container.SetParameter('/cell/soma', 'INJECT', 1e-09)

#
# Must create solver.
#
my_heccer = scheduler.CreateSolver('My solver', 'heccer')

# Sets the segment of the model to run from
my_heccer.SetModelName('/cell')

# set the timestep for the entire scheduler (solvers, inputs and outputs)
my_heccer.SetTimeStep(2e-05)

# Create a perfectclamp object for current holding.
my_input = scheduler.CreateInput('My perfectclamp', 'perfectclamp')

#
# Create Outputs
#
my_output = scheduler.CreateOutput('My output object', 'double_2_ascii')

my_output.SetFilename('/tmp/output')

my_output.AddOutput('/cell/soma', 'Vm')

# This should probably just be arg flags or something, passing 'steps'
# seems a bit tacky.
my_output.SetMode('steps')

my_output.SetResolution(10)
Beispiel #2
0
# Not sure wether to give this a get/set method
my_heccer.options = 4

my_heccer.SetGranularity(1000)

# Sets the segment of the model to run from
my_heccer.SetModelName('/singlep')

# set the timestep for the entire scheduler (solvers, inputs and outputs)
my_heccer.SetTimeStep(1e-05)

#
# Create a perfectclamp object for current holding.
#
my_input = scheduler.CreateInput('purkinje cell perfect clamp', 'perfectclamp')

my_input.AddInput('/singlep/segments/soma', 'Vm')

my_input.SetCommand(-0.06)

#
# Create Outputs
#
my_output = scheduler.CreateOutput('My output object', 'double_2_ascii')

my_output.SetFilename('/tmp/output')

my_output.AddOutput('/singlep/segments/soma', 'Vm')

my_output.SetMode('steps')
# Not sure wether to give this a get/set method
my_heccer.options = 4

my_heccer.SetGranularity(1)

# Sets the segment of the model to run from
my_heccer.SetModelName('/Purkinje')

# set the timestep for the entire scheduler (solvers, inputs and outputs)
my_heccer.SetTimeStep(2e-05)

#
# Create a pulsegen object for current holding.
#
my_pulsegen = scheduler.CreateInput('pulsegen', 'pulsegen')

my_pulsegen.AddInput('/Purkinje/segments/soma', 'INJECT')

my_pulsegen.SetLevel1(0.5e-09)
my_pulsegen.SetWidth1(0.15)
my_pulsegen.SetDelay1(0.05)
my_pulsegen.SetLevel2(0.0)
my_pulsegen.SetWidth2(0.0)
my_pulsegen.SetDelay2(100.0)  # give it a very long delay to prevent repeating

my_pulsegen.SetBaseLevel(0.0)
my_pulsegen.SetTriggerMode(2)  # zero is "ext gate"

#
# Create Outputs