In [ ]:
    
### Define Model Setup Steps
    
In [1]:
    
modelPath = 'Models/Davison2003/bulbNet'
modelName = 'Davison2003'
def getSomaScript(h):
    
    h.load_file('mosinit.hoc')
    h.run_experiment('odour_baseline')
    soma = h.Mit[0].soma
    
    return soma
    
In [2]:
    
%matplotlib inline
import helpers
mod1 = helpers.createModel(name = modelName, \
                           path = modelPath, \
               getSectionScript = getSomaScript)
    
In [3]:
    
# Interactively find stimulation currents
helpers.IClampWidget(mod1)
    
    
In [4]:
    
from quantities import nA, s, ms
##### Set currents
i_rest =    {'amplitude':     0*nA, 'delay': 0.5*s, 'duration': 1*s}
i_passive = {'amplitude': -0.07*nA, 'delay': 0.5*s, 'duration': 1*s}
i_ap  =     {'amplitude':     7*nA, 'delay': 0.5*s, 'duration': 1*ms}
i_thresh =  {'amplitude':  0.135*nA, 'delay': 0.5*s, 'duration': 1000*ms}
    
In [5]:
    
# Initialize the tests and get their expected values
tests = helpers.setupTests(i_rest, i_passive, i_ap, i_thresh, expectedSource = "Pooled")
helpers.runOneTest(tests[0], mod1)
    
    
    
    Out[5]:
In [6]:
    
results = helpers.runAllTests(tests, mod1)
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
In [7]:
    
    
    
In [11]:
    
pp(results)
helpers.saveResults(results)
pp(helpers.loadResults())
    
    
In [ ]:
    
mod1.h.quit()
    
In [ ]: