Perceptron with metrics for shogun and scikit