The problem is the following: when running these lines of code
grid = GridSearchCV(estimator=model, param_grid=param_grid, n_jobs=-1)
grid_result = grid.fit(X, y)
on Google Colab, it returns the error
PicklingError: Could not pickle the task to send it to the workers.
However, if I set n_jobs = 1, it perfectly works.
How can I use multiple processors on Google Colab?