added outerloop to Neuron