Implementation of a SVM