Ih tunes oscillations in an In Silico CA3 model (Neymotin et al. 2013)

 Download zip file   Auto-launch 
Help downloading and running models
Accession:151282
" ... We investigated oscillatory control using a multiscale computer model of hippocampal CA3, where each cell class (pyramidal, basket, and oriens-lacunosum moleculare cells), contained type-appropriate isoforms of Ih. Our model demonstrated that modulation of pyramidal and basket Ih allows tuning theta and gamma oscillation frequency and amplitude. Pyramidal Ih also controlled cross-frequency coupling (CFC) and allowed shifting gamma generation towards particular phases of the theta cycle, effected via Ih’s ability to set pyramidal excitability. ..."
Reference:
1 . Neymotin SA, Hilscher MM, Moulin TC, Skolnick Y, Lazarewicz MT, Lytton WW (2013) Ih Tunes Theta/Gamma Oscillations and Cross-Frequency Coupling In an In Silico CA3 Model PLoS ONE 8(10):e76285 [PubMed]
Model Information (Click on a link to find other models with that property)
Model Type: Realistic Network;
Brain Region(s)/Organism: Hippocampus;
Cell Type(s): Hippocampus CA3 pyramidal cell; Hippocampus CA3 interneuron basket cell; Hippocampus CA3 stratum oriens lacunosum-moleculare interneuron;
Channel(s): I Na,t; I A; I K; I K,leak; I h; I K,Ca; I Sodium; I Potassium;
Gap Junctions:
Receptor(s): GabaA; AMPA; NMDA; Glutamate;
Gene(s): HCN1; HCN2;
Transmitter(s): Gaba; Glutamate;
Simulation Environment: NEURON; Python;
Model Concept(s): Oscillations; Brain Rhythms; Conductance distributions; Multiscale;
Implementer(s): Lazarewicz, Maciej [mlazarew at gmu.edu]; Neymotin, Sam [samn at neurosim.downstate.edu];
Search NeuronDB for information about:  Hippocampus CA3 pyramidal cell; Hippocampus CA3 interneuron basket cell; GabaA; AMPA; NMDA; Glutamate; I Na,t; I A; I K; I K,leak; I h; I K,Ca; I Sodium; I Potassium; Gaba; Glutamate;
/
ca3ihdemo
readme.txt
CA3ih.mod
CA3ika.mod
CA3ikdr.mod
CA3ina.mod
caolmw.mod *
HCN1.mod
icaolmw.mod *
iholmw.mod
ihstatic.mod
kcaolmw.mod *
kdrbwb.mod *
misc.mod *
MyExp2SynBB.mod *
MyExp2SynNMDABB.mod *
nafbwb.mod *
stats.mod *
vecst.mod *
aux_fun.inc *
declist.hoc *
decmat.hoc *
decnqs.hoc *
decvec.hoc *
default.hoc *
drline.hoc *
geom.py
grvec.hoc *
init.hoc
labels.hoc *
local.hoc *
misc.h *
network.py
nqs.hoc *
nrnoc.hoc *
params.py
pyinit.py *
pywrap.hoc
run.py
sim.py
simctrl.hoc *
stats.hoc *
syncode.hoc *
xgetargs.hoc *
                            
# $Id: run.py,v 1.56 2012/09/20 14:06:03 samn Exp $ 

from pyinit import *
from geom import *
# from network import *
# from params import *
import sys
try:
  import filt
except:
  print "Couldn't import filt routines used in gethilbnqs"

# sets up external inputs
if net.noise:
	net.set_noise_inputs(h.tstop) #h.tstop sets duration of inpus for make noise case

# handler for printing out time during simulation run
def fi():
	for i in range(0,int(h.tstop),100):
		h.cvode.event(i, "print " + str(i))

fih = h.FInitializeHandler(1, fi)

# initialize random # generators of NetStims - forces it at beginning of each sim
def myInitNetStims():
	net.init_NetStims()
		
fihns = h.FInitializeHandler(0, myInitNetStims)

# save LFP with current pyramidal cell voltages
_svNUM = 0
def saveLFPInterm (fbase):
	global _svNUM
	fout = fbase + "_svNUM_" + str(_svNUM) + "_lfp.vec"
	print "time is " , h.t, " saving LFP to " , fout
	net.calc_lfp()
	mysvvec(fout,net.vlfp)
	net.clear_mem()
	_svNUM += 1

# setup events to save LFP intermittently
_svFBase = "./tmp_"
_svINC = 1000
def setSaveLFPEvents ():
	global _svNUM
	_svNUM = 0
	stre = "nrnpython(\"saveLFPInterm(_svFBase)\")"
	for tt in xrange(_svINC,int(h.tstop),_svINC):
		h.cvode.event(tt,stre)
	h.cvode.event(h.tstop,stre)

# example to save LFP intermittently: 
#  fisv = h.FInitializeHandler(0, setSaveLFPEvents)

#save vec to fn (fn is path)
def mysvvec(fn,vec):
	fp = h.File()
	fp.wopen(fn)
	if fp.isopen():
		vec.vwrite(fp)
		fp.close()
	else:
		print "savevec ERR: couldn't open " + fn

#run a sim and save data
def minrunsv (simstr,tstop=1200,dt=0.1,savevolt=False):
  h.tstop=tstop
  h.dt=dt
  h.run()
  print "saving output data"
  net.calc_lfp()
  fn = "./data/"+simstr+"_lfp.vec"
  mysvvec(fn,net.vlfp)
  net.setsnq() # make NQS with spike times
  fn = "./data/"+simstr+"_snq.nqs"
  net.snq.sv(fn)
  if savevolt:
    nqv = net.getnqvolt()
    nqv.sv('./data/'+simstr+'_nqvolt.nqs')

#read a Vector from file, fn is file-path, vec is a Vector
def myrdvec(fn,vec):
  fp=h.File()
  fp.ropen(fn)
  if not fp.isopen():
    print "myrdvec ERRA: Couldn't open " + fn
    return False
  vec.vread(fp)
  fp.close()
  return True

# concat a series of LFPs - fbase is base of filename
def catlfp (fbase,svn):
  vlfp, vtmp = h.Vector(), h.Vector()
  for i in xrange(svn):
    fin = fbase + "_svNUM_" + str(i) + "_lfp.vec"
    if myrdvec(fin,vtmp): vlfp.append(vtmp)
  return vlfp

#load data from minrunsv into net.vlfp,net.snq
def loadminrundat(simstr,datadir="./data/",rdvolt=False):
  fs = datadir+simstr+"_lfp.vec"
  try:
    net.vlfp.resize(0)
  except:
    net.vlfp = h.Vector()
    myrdvec(fs,net.vlfp)
  fs = datadir+simstr+"_snq.nqs"
  try:
    h.nqsdel(net.snq)		
  except:
    pass
  try:
    net.snq=h.NQS(fs)
  except:
    print "loadminrundat ERRB: couldn't read snq from " + fs
  net.snq.verbose=0 # next, copy snq into vectors so can plot with net.rasterplot
  for po in net.cells:
    for i in xrange(len(po.lidvec)):
      ID = po.cell[i].id
      po.lidvec[i].resize(0)
      po.ltimevec[i].resize(0)
      if net.snq.select("id",ID):
        po.lidvec[i].copy(net.snq.getcol("id"))
        po.ltimevec[i].copy(net.snq.getcol("t"))
  net.snq.verbose=1
  if rdvolt:
    try:
      h.nqsdel(net.nqv)
    except:
      pass
    fs = datadir+simstr+'_nqvolt.nqs'
    try:
      net.nqv=h.NQS(fs)
    except:
      print "loadminrundat ERRC: couldn't read nqvolt from " + fs

def myrast(spikes,times,sz=12):	
  if h.g[0] == None:
    h.gg()
  spikes.mark(h.g[0],times,"O",sz,1,1)
  h.g[0].exec_menu("View = plot")

############################
#   setup multithreading   #
pc = h.ParallelContext()   #
pc.nthread(32)             #
############################
####################################################################################################

Loading data, please wait...