By using GridSearchCV I can obtain clf.cv_results_['params'] and I would like to run over all the possible combinations and printing some probabilities:
for params in zip(clf.cv_results_['params']):
print(params)
clf= SVC(params)
clf.fit(X_train, y_train)
z_test=clf.predict(X_test)
print("Probability 1:", prob_error(y_test,z_test))
print("Probability 2:", average_error(y_test,z_test))
However, in params I obtain this:
({'C': 1000, 'gamma': 1000, 'tol': 2},)
How can I transform this in order to do the fit of the algorithm? Because this code has an error in "clf.fit(X_train, y_train)":
TypeError: must be real number, not tuple