title: sklearn.ensemble.AdaBoostClassifier cannot accecpt SVM as base_estimator?
body: <p>I am doing a text classification task. Now I want to use <code>ensemble.AdaBoostClassifier</code> with <code>LinearSVC</code> as <code>base_estimator</code>. However, when I try to run the code </p>
  
  <pre><code>clf = AdaBoostClassifier(svm.LinearSVC(),n_estimators=50, learning_rate=1.0,    algorithm='SAMME.R')
  clf.fit(X, y)
  </code></pre>
  
  <p>An error occurred. <code>TypeError: AdaBoostClassifier with algorithm='SAMME.R' requires that the weak learner supports the calculation of class probabilities with a predict_proba method</code></p>
  
  <p><strong>The first question is</strong> Cannot the <code>svm.LinearSVC()</code> calculate the class probabilities ? How to make it calculate the probabilities?</p>
  
  <p>Then I Change the parameter <code>algorithm</code> and run the code again.</p>
  
  <pre><code>clf = AdaBoostClassifier(svm.LinearSVC(),n_estimators=50, learning_rate=1.0, algorithm='SAMME')
  clf.fit(X, y)
  </code></pre>
  
  <p>This time <code>TypeError: fit() got an unexpected keyword argument 'sample_weight'</code> happens. As is said in <a href="http://scikit-learn.org/stable/modules/generated/sklearn.ensemble.AdaBoostClassifier.html#sklearn.ensemble.AdaBoostClassifier" rel="noreferrer">AdaBoostClassifier</a>, <code>Sample weights. If None, the sample weights are initialized to 1 / n_samples.</code> Even if I assign an integer to <code>n_samples</code>, error also occurred. </p>
  
  <p><strong>The second question is</strong> What does <code>n_samples</code> mean? How to solve this problem? </p>
  
  <p>Hope anyone could help me.</p>
  
  <p>According to @jme 's comment, however, after trying</p>
  
  <pre><code>clf = AdaBoostClassifier(svm.SVC(kernel='linear',probability=True),n_estimators=10,  learning_rate=1.0, algorithm='SAMME.R')
  clf.fit(X, y)
  </code></pre>
  
  <p>The program cannot get a result and the memory used on the server keeps unchanged.</p>
  
  <p><strong>The third question is</strong> how I can make <code>AdaBoostClassifier</code> work with <code>SVC</code> as base_estimator?</p>