Added flag to use the perceptron rather than backprop.