title: Writing scikit-learn verbose log into an external file
body: <p>I am trying to optimize an SVR model using <code>GridSearchCV</code> and facing a problem because of overfitting, to overcome this I have tried to decrease the number of iterations instead of leaving it until convergence.To compare the both models I need the number of iterations for both cases. </p>
  
  <p>I tried to do this through <code>verbose = 1</code> but it didn't work in jupyter notebook. I need to access the number of iterations and save it as a variable to plot the results of optimization. Writing the verbose log to an external file could solve the problem but I am not able to do it.</p>
  
  <p>I got some information from a previous question 
  <a href="https://stackoverflow.com/questions/41486610/knowing-the-number-of-iterations-needed-for-convergence-in-svr-scikit-learn">Knowing the number of iterations needed for convergence in SVR scikit-learn</a>
  but still not able to solve the problem</p>
  
  <p>Here is a sample of my code:</p>
  
  <pre><code>model_1=SVR(kernel='rbf',C=316,epsilon=0, gamma=0.003162,max_iter=2500,verbose=1)
  model_1.fit(tr_sets[:,:2],tr_sets[:,2])
  </code></pre>