Logistic Regression:
logisticregressionC: This key defines the regularization parameter (C) for logistic regression.
logisticregressionsolver: This key specifies the solver algorithm for logistic regression.
Support Vector Machine:
svcC: Key defines the regularization parameter (C) for SVM.
svckernel: This key defines the kernel function used by the SVM.
svc__gamma: It defines the gamma parameter that controls the influence of training points on the decision boundary.
Used GridSearchCV to build a pipeline using hyperparameters.
cv = 10: This sets the number of cross-validation folds to 10.
n_jobs=-1: This instructs GridSearchCV to use all available CPU cores to parallelize the hyperparameter tuning process.
Created a Hyperparameters Grid.
Logistic Regression: logisticregressionC: This key defines the regularization parameter (C) for logistic regression. logisticregressionsolver: This key specifies the solver algorithm for logistic regression.
Support Vector Machine: svcC: Key defines the regularization parameter (C) for SVM. svckernel: This key defines the kernel function used by the SVM. svc__gamma: It defines the gamma parameter that controls the influence of training points on the decision boundary.
Used GridSearchCV to build a pipeline using hyperparameters.
cv = 10: This sets the number of cross-validation folds to 10.
n_jobs=-1: This instructs GridSearchCV to use all available CPU cores to parallelize the hyperparameter tuning process.
Put the models in a loop to find accuracy score.