Implement batch and online function for perceptron
Merge branch 'dev'