Removed warning, requiring to send dual explicitly to True.
This commit is contained in:
+1
-1
@@ -106,7 +106,7 @@ def calculate_recommendation(
|
||||
y[ptoi[pid]] = 1.0
|
||||
|
||||
# classify
|
||||
clf = svm.LinearSVC(class_weight='balanced', verbose=False, max_iter=10000, tol=1e-6, C=0.01)
|
||||
clf = svm.LinearSVC(class_weight='balanced', verbose=False, max_iter=10000, tol=1e-6, C=0.01, dual=True)
|
||||
clf.fit(x, y)
|
||||
s = clf.decision_function(x)
|
||||
sortix = np.argsort(-s)
|
||||
|
||||
Reference in New Issue
Block a user