Home | Trees | Indices | Help |
|
---|
|
One-vs-one multiclass strategy This node has been automatically generated by wrapping the ``sklearn.multiclass.OneVsOneClassifier`` class from the ``sklearn`` library. The wrapped instance can be accessed through the ``scikits_alg`` attribute. This strategy consists in fitting one classifier per class pair. At prediction time, the class which received the most votes is selected. Since it requires to fit `n_classes * (n_classes - 1) / 2` classifiers, this method is usually slower than one-vs-the-rest, due to its O(n_classes^2) complexity. However, this method may be advantageous for algorithms such as kernel algorithms which don't scale well with `n_samples`. This is because each individual learning problem only involves a small subset of the data whereas, with one-vs-the-rest, the complete dataset is used `n_classes` times. Read more in the :ref:`User Guide <ovo_classification>`. **Parameters** estimator : estimator object An estimator object implementing `fit` and one of `decision_function` or `predict_proba`. n_jobs : int, optional, default: 1 The number of jobs to use for the computation. If -1 all CPUs are used. If 1 is given, no parallel computing code is used at all, which is useful for debugging. For n_jobs below -1, (n_cpus + 1 + n_jobs) are used. Thus for n_jobs = -2, all CPUs but one are used. **Attributes** ``estimators_`` : list of `n_classes * (n_classes - 1) / 2` estimators Estimators used for predictions. ``classes_`` : numpy array of shape [n_classes] Array containing labels.
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
Inherited from Inherited from Inherited from |
|||
Inherited from ClassifierCumulator | |||
---|---|---|---|
|
|||
|
|||
|
|||
Inherited from ClassifierNode | |||
|
|||
|
|||
|
|||
|
|||
|
|||
Inherited from Node | |||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|
|||
|
|||
|
|
|||
Inherited from |
|||
Inherited from Node | |||
---|---|---|---|
_train_seq List of tuples: |
|||
dtype dtype |
|||
input_dim Input dimensions |
|||
output_dim Output dimensions |
|||
supported_dtypes Supported dtypes |
|
One-vs-one multiclass strategy This node has been automatically generated by wrapping the ``sklearn.multiclass.OneVsOneClassifier`` class from the ``sklearn`` library. The wrapped instance can be accessed through the ``scikits_alg`` attribute. This strategy consists in fitting one classifier per class pair. At prediction time, the class which received the most votes is selected. Since it requires to fit `n_classes * (n_classes - 1) / 2` classifiers, this method is usually slower than one-vs-the-rest, due to its O(n_classes^2) complexity. However, this method may be advantageous for algorithms such as kernel algorithms which don't scale well with `n_samples`. This is because each individual learning problem only involves a small subset of the data whereas, with one-vs-the-rest, the complete dataset is used `n_classes` times. Read more in the :ref:`User Guide <ovo_classification>`. **Parameters** estimator : estimator object An estimator object implementing `fit` and one of `decision_function` or `predict_proba`. n_jobs : int, optional, default: 1 The number of jobs to use for the computation. If -1 all CPUs are used. If 1 is given, no parallel computing code is used at all, which is useful for debugging. For n_jobs below -1, (n_cpus + 1 + n_jobs) are used. Thus for n_jobs = -2, all CPUs but one are used. **Attributes** ``estimators_`` : list of `n_classes * (n_classes - 1) / 2` estimators Estimators used for predictions. ``classes_`` : numpy array of shape [n_classes] Array containing labels.
|
|
|
Transform the data and labels lists to array objects and reshape them.
|
|
|
Estimate the best class label for each sample in X. This node has been automatically generated by wrapping the sklearn.multiclass.OneVsOneClassifier class from the sklearn library. The wrapped instance can be accessed through the scikits_alg attribute. This is implemented as argmax(decision_function(X), axis=1) which will return the label of the class with most votes by estimators predicting the outcome of a decision for each possible class pair. Parameters
Returns
|
Fit underlying estimators. This node has been automatically generated by wrapping the sklearn.multiclass.OneVsOneClassifier class from the sklearn library. The wrapped instance can be accessed through the scikits_alg attribute. Parameters
Returns self
|
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Tue Mar 8 12:39:48 2016 | http://epydoc.sourceforge.net |