def feed_forward(neural_network, input_vector):
 outputs = []
 for layer in neural_network:
  input_with_bias = (input_vector + [1])
  output = [neuron_output(neuron, input_with_bias) for neuron in layer]
  outputs.append(output)
  input_vector = output
 return outputs

def feed_forward ( neural_network , input_vector ) : outputs = [ ] for layer in neural_network : input_with_bias = ( input_vector + [ 1 ] ) output = [ neuron_output ( neuron , input_with_bias ) for neuron in layer ] outputs . append ( output ) input_vector = output return outputs
takes in a neural network and returns the output from forward-propagating the input .