input to a netcon synapse from an external file
Posted: Wed Sep 14, 2005 9:50 am
I tried to rewrite a simple Ampa-Synapse from Destexhe et. al with a rectangular transmitter pulse in order to a have a synapse, which is able to deal with NetCon-Events, so that using CVode during simulation is possible.
Everything went fine, until I tried to implement the synapse in hoc.
What I want to do is simulating a pyramidal hippocampal neuron, which gains its input through different synapses from files. The Files are pure ASCII-Files consisting of 0 and 1, which denote if a spike has arrived or not. Because a Netstim-Process can only have as a source a range variable I inserted a dummysoma, which is not connected to anything else and consists of one segment, loaded the files into a vector and played the vectors by brute force into the membranpotential of the dummysoma.
This is the hoc code:
i
AMPANETCON is the rewritten Ampa Synapse.
To figure out if the problem may be the new programmed AMPANETCON-Synapse, I tried the same with the "old Synapse"
AMPA is the "old synapse", vector1 the vector, where all the file datapoints are played in
This doesn't work at all (v(0) doesn't change at all), but if I replace v(0) with any arbitrary variable x, everything works fine.
Does anyone know a solution for feeding a NetCon-Synapse with data from file?
Thanks in advance
Marie-Therese
Everything went fine, until I tried to implement the synapse in hoc.
What I want to do is simulating a pyramidal hippocampal neuron, which gains its input through different synapses from files. The Files are pure ASCII-Files consisting of 0 and 1, which denote if a spike has arrived or not. Because a Netstim-Process can only have as a source a range variable I inserted a dummysoma, which is not connected to anything else and consists of one segment, loaded the files into a vector and played the vectors by brute force into the membranpotential of the dummysoma.
This is the hoc code:
i
Code: Select all
input = new File()
input.ropen("randomInput1.txt")
vector = new Vector(620000)
vector.scanf(input)
dummysoma vektor.play(&v(0), 0.025) /
objectvar NetConSynapse
dendbas {NetConSynapse = new AMPANETCON(0.2)}
objref nc
dummyinput=0
dummysoma nc = new NetCon(&v(0), NetConSynapse, 0.5, 0, 0)
To figure out if the problem may be the new programmed AMPANETCON-Synapse, I tried the same with the "old Synapse"
Code: Select all
dendbas{
noise1 = new AMPA(0.2)
inputnoise1=0}
stimdummy setpointer noise1.pre, v(0)
stimdummy vector1.play(&v(0), 0.025)
This doesn't work at all (v(0) doesn't change at all), but if I replace v(0) with any arbitrary variable x, everything works fine.
Does anyone know a solution for feeding a NetCon-Synapse with data from file?
Thanks in advance
Marie-Therese