Class OCSVM<V>

  • Type Parameters:
    V - Object type
    All Implemented Interfaces:
    Algorithm, OutlierAlgorithm

    @Reference(authors="B. Sch\u00f6lkopf, J. C. Platt, J. Shawe-Taylor, A. J. Smola, R. C. Williamson",
               title="Estimating the support of a high-dimensional distribution",
               booktitle="Neural computation 13.7",
    public class OCSVM<V>
    extends java.lang.Object
    implements OutlierAlgorithm
    Outlier-detection using one-class support vector machines.

    Important note: from literature, the one-class SVM is trained as if 0 was the only counterexample. Outliers will only be detected when they are close to the origin in kernel space! In our experience, results from this method are rather mixed, in particular as you would likely need to tune hyperparameters. Results may be better if you have a training data set with positive examples only, then apply it only to new data (which is currently not supported in this implementation, it assumes a single-dataset scenario).


    B. Schölkopf, J. C. Platt, J. Shawe-Taylor, A. J. Smola, R. C. Williamson
    Estimating the support of a high-dimensional distribution
    Neural computation 13.7

    Erich Schubert
    • Field Detail

      • LOG

        private static final Logging LOG
        Class logger.
      • nu

        double nu
        Nu parameter.
    • Constructor Detail

      • OCSVM

        public OCSVM​(PrimitiveSimilarity<? super V> kernel,
                     double nu)
        kernel - Kernel to use with SVM.
        nu - Nu parameter
    • Method Detail

      • getInputTypeRestriction

        public TypeInformation[] getInputTypeRestriction()
        Description copied from interface: Algorithm
        Get the input type restriction used for negotiating the data query.
        Specified by:
        getInputTypeRestriction in interface Algorithm
        Type restriction
      • run

        public OutlierResult run​(Relation<V> relation)
        Run one-class SVM.
        relation - Data relation
        Outlier result.