Updated perceptron to operate on vectors and do no input munging.

Signed-off-by: Nick Campbell <nicholas.j.campbell@gmail.com>