Documentation of 'jsat.classifiers.linear.kernelized.DUOL' Java class
DUOL
jsat.classifiers.linear.kernelized

Class DUOL

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable, BinaryScoreClassifier, Classifier, UpdateableClassifier, Parameterized


    public class DUOL
    extends BaseUpdateableClassifier
    implements BinaryScoreClassifier, Parameterized
    Provides an implementation of Double Update Online Learning (DUOL) algorithm. It is a kernelized extension of PassiveAggressive (PA-I) where one previously learned support vector may be updated upon each addition to the support vector set. The SV set is unbounded in size. The objective function is not identical because of the dual updates.

    Using a larger C value for DUOL has theoretical improvements, as it increases the number of "strong" dual updates. The default value is set to 10 as suggested in the paper. See:
    • Zhao, P., Hoi, S. C. H.,&Jin, R. (2011). Double Updating Online Learning. Journal of Machine Learning Research, 12, 1587–1615. Retrieved from here
    • Zhao, P., Hoi, S. C. H.,&Jin, R. (2009). DUOL: A Double Updating Approach for Online Learning. In Y. Bengio, D. Schuurmans, J. Lafferty, C. K. I. Williams,&A. Culotta (Eds.), Advances in Neural Information Processing Systems 22 (pp. 2259–2267).
    See Also:
    Serialized Form
    • Constructor Detail

      • DUOL

        public DUOL(KernelTrick k)
        Creates a new DUOL learner
        Parameters:
        k - the kernel to use
    • Method Detail

      • setC

        public void setC(double C)
        Sets the aggressiveness parameter. Increasing the value of this parameter increases the aggressiveness of the algorithm. It must be a positive value. This parameter essentially performs a type of regularization on the updates
        Parameters:
        C - the aggressiveness parameter in (0, Inf)
      • getC

        public double getC()
        Returns the aggressiveness parameter
        Returns:
        the aggressiveness parameter
      • setRho

        public void setRho(double rho)
        Sets the "conflict" parameter, which controls how often double updates are performed. Smaller (near zero) values tend to produce more double updates, with values near 1 producing few double updates. The value must be in the range [0, 1]
        Parameters:
        rho - the conflict parameter for when to update a second support vector
      • getRho

        public double getRho()
        Returns the "conflict" parameter value for the threshold of performing double updates
        Returns:
        the "conflict" parameter value for the threshold of performing double updates
      • setKernel

        public void setKernel(KernelTrick k)
        Sets the kernel trick to use
        Parameters:
        k - the kernel trick to use
      • getKernel

        public KernelTrick getKernel()
        Returns the kernel trick in use
        Returns:
        the kernel trick in use
      • update

        public void update(DataPoint dataPoint,
                           int targetClass)
        Description copied from interface: UpdateableClassifier
        Updates the classifier by giving it a new data point to learn from.
        Specified by:
        update in interface UpdateableClassifier
        Parameters:
        dataPoint - the data point to learn
        targetClass - the target class of the data point
      • classify

        public CategoricalResults classify(DataPoint data)
        Description copied from interface: Classifier
        Performs classification on the given data point.
        Specified by:
        classify in interface Classifier
        Parameters:
        data - the data point to classify
        Returns:
        the results of the classification.
      • getScore

        public double getScore(DataPoint dp)
        Description copied from interface: BinaryScoreClassifier
        Returns the numeric score for predicting a class of a given data point, where the sign of the value indicates which class the data point is predicted to belong to.
        Specified by:
        getScore in interface BinaryScoreClassifier
        Parameters:
        dp - the data point to predict the class label of
        Returns:
        the score for the given data point
      • supportsWeightedData

        public boolean supportsWeightedData()
        Description copied from interface: Classifier
        Indicates whether the model knows how to train using weighted data points. If it does, the model will train assuming the weights. The values returned by this method may change depending on the parameters set for the model.
        Specified by:
        supportsWeightedData in interface Classifier
        Returns:
        true if the model supports weighted data, false otherwise
      • guessC

        public static Distribution guessC(DataSet d)
        Guesses the distribution to use for the C parameter
        Parameters:
        d - the dataset to get the guess for
        Returns:
        the guess for the C parameter
        See Also:
        setC(double)

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.