本文整理汇总了Python中ucl.physiol.neuroconstruct.project.ProjectManager.doRunGenesis方法的典型用法代码示例。如果您正苦于以下问题:Python ProjectManager.doRunGenesis方法的具体用法?Python ProjectManager.doRunGenesis怎么用?Python ProjectManager.doRunGenesis使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ucl.physiol.neuroconstruct.project.ProjectManager
的用法示例。
在下文中一共展示了ProjectManager.doRunGenesis方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: generateF_ICurve
# 需要导入模块: from ucl.physiol.neuroconstruct.project import ProjectManager [as 别名]
# 或者: from ucl.physiol.neuroconstruct.project.ProjectManager import doRunGenesis [as 别名]
#.........这里部分代码省略.........
print "Next stim: "+ str(stim)
self.myProject.simulationParameters.setReference(simRef)
if simulator == "NEURON":
self.myProject.neuronFileManager.generateTheNeuronFiles(simConfig,
None,
NeuronFileManager.RUN_HOC,
self.simulatorSeed)
print "Generated NEURON files for: "+simRef
compileProcess = ProcessManager(self.myProject.neuronFileManager.getMainHocFile())
compileSuccess = compileProcess.compileFileWithNeuron(0,0)
print "Compiled NEURON files for: "+simRef
if compileSuccess:
pm.doRunNeuron(simConfig)
print "Set running simulation: "+simRef
self.simsRunning.append(simRef)
if simulator == "GENESIS":
compartmentalisation = GenesisCompartmentalisation()
self.myProject.genesisFileManager.generateTheGenesisFiles(simConfig,
None,
compartmentalisation,
self.simulatorSeed)
print "Generated GENESIS files for: "+simRef
pm.doRunGenesis(simConfig)
print "Set running simulation: "+simRef
self.simsRunning.append(simRef)
time.sleep(1) # Wait for sim to be kicked off
simReferences[simRef] = stimAmp
stimAmp = stimAmp +stimAmpInc
print
print "Finished running "+str(len(simReferences))+" simulations for project "+ projFile.getAbsolutePath()
print "These can be loaded and replayed in the previous simulation browser in the GUI"
print
while (len(self.simsRunning)>0):
print "Sims currently running: "+str(self.simsRunning)
print "Waiting..."
time.sleep(4) # wait a while...
self.updateSimsRunning()
#simReferences = {'PySim_0.3':0.3,'PySim_0.4':0.4,'PySim_0.5':0.5}
plotFrameFI = PlotManager.getPlotterFrame("F-I curve from project: "+str(self.myProject.getProjectFile())+" on "+simulator , 1, 1)
plotFrameVolts = PlotManager.getPlotterFrame("VoltageTraces from project: "+str(self.myProject.getProjectFile())+" on "+simulator , 1, 1)
plotFrameFI.setViewMode(PlotCanvas.INCLUDE_ORIGIN_VIEW)
info = "F-I curve for Simulation Configuration: "+str(simConfig)
dataSet = DataSet(info, info, "nA", "Hz", "Current injected", "Firing frequency")
dataSet.setGraphFormat(PlotCanvas.USE_CIRCLES_FOR_PLOT)
simList = simReferences.keys()
simList.sort()
示例2: make_fF_Curve
# 需要导入模块: from ucl.physiol.neuroconstruct.project import ProjectManager [as 别名]
# 或者: from ucl.physiol.neuroconstruct.project.ProjectManager import doRunGenesis [as 别名]
#.........这里部分代码省略.........
print "Next Train: "+ str(currentTrain)
self.myProject.simulationParameters.setReference(simRef)
if simulator == "NEURON":
self.myProject.neuronFileManager.generateTheNeuronFiles(simConfig,
None,
NeuronFileManager.RUN_HOC,
self.simulatorSeed)
print "Generated NEURON files for: "+simRef
compileProcess = ProcessManager(self.myProject.neuronFileManager.getMainHocFile())
compileSuccess = compileProcess.compileFileWithNeuron(0,0)
print "Compiled NEURON files for: "+simRef
if compileSuccess:
pm.doRunNeuron(simConfig)
print "Set running simulation: "+simRef
self.simsRunning.append(simRef)
if simulator == "GENESIS":
compartmentalisation = GenesisCompartmentalisation()
self.myProject.genesisFileManager.generateTheGenesisFiles(simConfig,
None,
compartmentalisation,
self.simulatorSeed)
print "Generated GENESIS files for: "+simRef
pm.doRunGenesis(simConfig)
print "Set running simulation: "+simRef
self.simsRunning.append(simRef)
time.sleep(1) # Wait for sim to be kicked off
simReferences[simRef] = currentTrain
currentTrain = currentTrain + 1
print
print "Finished running "+str(len(simReferences))+" simulations for project "+ projFile.getAbsolutePath()
print "These can be loaded and replayed in the previous simulation browser in the GUI"
print
while (len(self.simsRunning)>0):
print "Sims currently running: "+str(self.simsRunning)
print "Waiting..."
time.sleep(4) # wait a while...
self.updateSimsRunning()
#simReferences = {'PySim_0.3':0.3,'PySim_0.4':0.4,'PySim_0.5':0.5}
plotFrameFf = PlotManager.getPlotterFrame("F-f curve from project: "+str(self.myProject.getProjectFile())+" on "+simulator , 1, 1)
plotFrameVolts = PlotManager.getPlotterFrame("VoltageTraces from project: "+str(self.myProject.getProjectFile())+" on "+simulator , 1, 1)
plotFrameFf.setViewMode(PlotCanvas.INCLUDE_ORIGIN_VIEW)
info = "F-f curve for Simulation Configuration: "+str(simConfig)
dataSet = DataSet(info, info, "Hz", "Hz", "Input_Freq", "Output_Freq")
dataSet.setGraphFormat(PlotCanvas.USE_CIRCLES_FOR_PLOT)
simList = simReferences.keys()
示例3: generateV_ICurve
# 需要导入模块: from ucl.physiol.neuroconstruct.project import ProjectManager [as 别名]
# 或者: from ucl.physiol.neuroconstruct.project.ProjectManager import doRunGenesis [as 别名]
#.........这里部分代码省略.........
print "Next stim: "+ str(stimAmp)
self.myProject.simulationParameters.setReference(simRef)
if simulator == "NEURON":
self.myProject.neuronFileManager.generateTheNeuronFiles(simConfig,
None,
NeuronFileManager.RUN_HOC,
self.simulatorSeed)
print "Generated NEURON files for: "+simRef
compileProcess = ProcessManager(self.myProject.neuronFileManager.getMainHocFile())
compileSuccess = compileProcess.compileFileWithNeuron(0,0)
print "Compiled NEURON files for: "+simRef
if compileSuccess:
pm.doRunNeuron(simConfig)
print "Set running simulation: "+simRef
self.simsRunning.append(simRef)
if simulator == "GENESIS":
compartmentalisation = GenesisCompartmentalisation()
self.myProject.genesisFileManager.generateTheGenesisFiles(simConfig,
None,
compartmentalisation,
self.simulatorSeed)
print "Generated GENESIS files for: "+simRef
pm.doRunGenesis(simConfig)
print "Set running simulation: "+simRef
self.simsRunning.append(simRef)
time.sleep(1) # Wait for sim to be kicked off
simReferences[simRef] = stimAmp
stimAmp = stimAmp +stimAmpInc
print
print "Finished running "+str(len(simReferences))+" simulations for project "+ projFile.getAbsolutePath()
print "These can be loaded and replayed in the previous simulation browser in the GUI"
print
while (len(self.simsRunning)>0):
print "Sims currently running: "+str(self.simsRunning)
print "Waiting..."
time.sleep(4) # wait a while...
self.updateSimsRunning()
#simReferences = {'PySim_0.3':0.3,'PySim_0.4':0.4,'PySim_0.5':0.5}
plotFrameVI = PlotManager.getPlotterFrame("V-I curve from project: "+str(self.myProject.getProjectFile())+" on "+simulator , 1, 1)
plotFrameVI.setViewMode(PlotCanvas.INCLUDE_ORIGIN_VIEW)
info = "V-I curve for Simulation Configuration: "+str(simConfig)
dataSet = DataSet(info, info, "mV", "nA", "Voltage", "Current")
dataSet.setGraphFormat(PlotCanvas.USE_CIRCLES_FOR_PLOT)
simList = simReferences.keys()
simList.sort()