Major SVM bugfix