You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
In certain cases the SVM training fails to converge to the target tolerance in a reasonable time.
One such case is the following:
iris = load_iris()
X = iris.data
y = iris.target
# we only keep the first two features in X and sub-sample the dataset to keep
# only 2 classes and make it a binary classification problem.
X_2d = X[:, :2]
X_2d = X_2d[y > 0]
y_2d = y[y > 0]
y_2d -= 1
scaler = StandardScaler()
X = scaler.fit_transform(X)
X_2d = scaler.fit_transform(X_2d)
params = {'kernel':'poly', 'C': 10, 'gamma': 1e1, 'verbose':1}
sklSVC = sklearn.svm.SVC(**params)
sklSVC.fit(X_2d, y_2d)
cuSVC = cuml.svm.SVC(**params)
cuSVC.fit(X_2d, y_2d)
Likely cause is an oscillation in the diff parameter. Such oscillation could happen if the same set of vectors are getting in and out of the working set,
Describe the solution you'd like
Detect if there is an oscillation in the diff parameter
Stop training in such case
Describe alternatives you've considered
Currently the training would stop if the number of maximum iterations are reached.
Additional context
This is slightly related to #946, because the working set selection method influences what kind of problems can occur with the convergence.
The text was updated successfully, but these errors were encountered:
The training can still converge if the diff parameter oscillates. This will be addressed with a debug message which gives advice how to improve the convergence.
closes#947
If the input data for SVM is not normalized correctly, then convergence can be very slow. The solver can even fail to converge. This PR detects such cases and prints a debug message with suggestions how to fix this problem.
Such problems were reported in #947, #1664, #2857, #3233. The threshold for reporting is set so that the message is printed in those cases. I have tested several properly normalized cases to confirm that the message is not shown. Still, the threshold for printing the message does not have a proper theoretical justification, and false positives might occur. Therefore only a debug message is shown instead of a warning.
Authors:
- Tamas Bela Feher (@tfeher)
Approvers:
- Dante Gama Dessavre (@dantegd)
URL: #3562
Is your feature request related to a problem? Please describe.
In certain cases the SVM training fails to converge to the target tolerance in a reasonable time.
One such case is the following:
Likely cause is an oscillation in the diff parameter. Such oscillation could happen if the same set of vectors are getting in and out of the working set,
Describe the solution you'd like
Describe alternatives you've considered
Currently the training would stop if the number of maximum iterations are reached.
Additional context
This is slightly related to #946, because the working set selection method influences what kind of problems can occur with the convergence.
The text was updated successfully, but these errors were encountered: