Evaluates the testing data by computing the prediction value and returning a pair of true label value and prediction value.
Evaluates the testing data by computing the prediction value and returning a pair of true label value and prediction value. It is important that the implementation chooses a Testing type from which it can extract the true label value.
Fits the estimator to the given input data.
Fits the estimator to the given input data. The fitting logic is contained in the FitOperation. The computed state will be stored in the implementing class.
Type of the training data
Training data
Additional parameters for the FitOperation
FitOperation which encapsulates the algorithm logic
Predict testing data according the learned model.
Predict testing data according the learned model. The implementing class has to provide a corresponding implementation of PredictDataSetOperation which contains the prediction logic.
Type of the testing data
Type of the prediction data
Testing data which shall be predicted
Additional parameters for the prediction
PredictDataSetOperation which encapsulates the prediction logic
Sets the number of data blocks/partitions
Sets the number of data blocks/partitions
the number of blocks into which the input data will be split.
itself
Sets the number of outer iterations
Sets the number of outer iterations
the maximum number of iterations of the outer loop method
itself
Sets the number of local SDCA iterations
Sets the number of local SDCA iterations
the maximum number of SDCA iterations
itself
Sets whether the predictions should return the raw decision function value or the thresholded binary value.
Sets whether the predictions should return the raw decision function value or the thresholded binary value.
When setting this to true, predict and evaluate return the raw decision value, which is the distance from the separating hyperplane. When setting this to false, they return thresholded (+1.0, -1.0) values.
When set to true, and evaluate return the raw decision function values. When set to false, they return the thresholded binary values (+1.0, -1.0).
itself
Sets the regularization constant
Sets the regularization constant
the regularization constant of the SVM algorithm
itself
Sets the seed value for the random number generator
Sets the seed value for the random number generator
the seed to initialize the random number generator
itself
Sets the stepsize for the weight vector updates
Sets the stepsize for the weight vector updates
the initial step size for the updates of the weight vector
itself
Sets the threshold above which elements are classified as positive.
Sets the threshold above which elements are classified as positive.
The and evaluate functions will return +1.0 for items with a decision function value above this threshold, and -1.0 for items below it.
the limiting value for the decision function above which examples are labeled as positive
itself
Stores the learned weight vector after the fit operation
Implements a soft-margin SVM using the communication-efficient distributed dual coordinate ascent algorithm (CoCoA) with hinge-loss function.
It can be used for binary classification problems, with the labels set as +1.0 to indicate a positive example and -1.0 to indicate a negative example.
The algorithm solves the following minimization problem:
min_{w in bbb"R"d} lambda/2 ||w||2 + 1/n sum_(i=1)n l_{i}(wTx_i)
with
w
being the weight vector,lambda
being the regularization constant,x_{i} in bbb"R"^d
being the data points and
l_{i}being the convex loss functions, which can also depend on the labels
y_{i} in bbb"R". In the current implementation the regularizer is the 2-norm and the loss functions are the hinge-loss functions:
l_{i} = max(0, 1 - y_{i} * w^Tx_i
With these choices, the problem definition is equivalent to a SVM with soft-margin. Thus, the algorithm allows us to train a SVM with soft-margin.
The minimization problem is solved by applying stochastic dual coordinate ascent (SDCA). In order to make the algorithm efficient in a distributed setting, the CoCoA algorithm calculates several iterations of SDCA locally on a data block before merging the local updates into a valid global state. This state is redistributed to the different data partitions where the next round of local SDCA iterations is then executed. The number of outer iterations and local SDCA iterations control the overall network costs, because there is only network communication required for each outer iteration. The local SDCA iterations are embarrassingly parallel once the individual data partitions have been distributed across the cluster.
Further details of the algorithm can be found here.
Parameters
stepsize/blocks
. This value has to be tuned in case that the algorithm becomes instable. (Default value: 1.0)