/**
* @see ca.nengo.model.neuron.Neuron#run(float, float)
*/
public void run(float startTime, float endTime) throws SimulationException {
//TODO: this method could use some cleanup and optimization
TimeSeries1D current = myIntegrator.run(startTime, endTime);
float[] integratorOutput = current.getValues1D();
float[] generatorInput = new float[integratorOutput.length];
for (int i = 0; i < integratorOutput.length; i++) {
myUnscaledCurrent = (myRadialInput + integratorOutput[i]);
generatorInput[i] = myBias + myScale * myUnscaledCurrent;
if (myNoise != null) {
generatorInput[i] = myNoise.getValue(startTime, endTime, generatorInput[i]);
}
}
myCurrent = new TimeSeries1DImpl(current.getTimes(), generatorInput, Units.UNK);
mySpikeOrigin.run(myCurrent.getTimes(), generatorInput);
myCurrentOrigin.setValues(startTime, endTime, new float[]{myUnscaledCurrent});
}