title: How to pass elegantly Sklearn's GridseachCV's best parameters to another model?
body: <p>I have found a set of best hyperparameters for my KNN estimator with Grid Search CV:</p>
  
  <pre><code>&gt;&gt;&gt; knn_gridsearch_model.best_params_
  {'algorithm': 'auto', 'metric': 'manhattan', 'n_neighbors': 3}
  </code></pre>
  
  <p>So far, so good. I want to train my final estimator with these new-found parameters. Is there a way to feed the above hyperparameter dict to it directly? I tried this:</p>
  
  <pre><code>&gt;&gt;&gt; new_knn_model = KNeighborsClassifier(knn_gridsearch_model.best_params_)
  </code></pre>
  
  <p>but instead the hoped result <code>new_knn_model</code> just got the whole dict as the first parameter of the model and left the remaining ones as default:</p>
  
  <pre><code>&gt;&gt;&gt; knn_model
  KNeighborsClassifier(algorithm='auto', leaf_size=30, metric='minkowski',
             metric_params=None, n_jobs=1,
             n_neighbors={'n_neighbors': 3, 'metric': 'manhattan', 'algorithm': 'auto'},
             p=2, weights='uniform')
  </code></pre>
  
  <p>Disappointing indeed.</p>