title: VotingClassifier with pipelines as estimators
body: <p>I want to build an sklearn <code>VotingClassifier</code> ensemble out of multiple different models (Decision Tree, SVC, and a Keras Network). All of them need a different kind of data preprocessing, which is why I made a pipeline for each of them. </p>
  
  <pre class="lang-py prettyprint-override"><code># Define pipelines
  
  # DTC pipeline
  featuriser = Featuriser()
  dtc = DecisionTreeClassifier()
  dtc_pipe = Pipeline([('featuriser',featuriser),('dtc',dtc)])
  
  # SVC pipeline
  scaler = TimeSeriesScalerMeanVariance(kind='constant')
  flattener = Flattener()
  svc = SVC(C = 100, gamma = 0.001, kernel='rbf')
  svc_pipe = Pipeline([('scaler', scaler),('flattener', flattener), ('svc', svc)])
  
  # Keras pipeline
  cnn = KerasClassifier(build_fn=get_model())
  cnn_pipe = Pipeline([('scaler',scaler),('cnn',cnn)])
  
  # Make an ensemble
  ensemble = VotingClassifier(estimators=[('dtc', dtc_pipe), 
                                          ('svc', svc_pipe),
                                          ('cnn', cnn_pipe)], 
                              voting='hard')
  
  </code></pre>
  
  <p>The <code>Featuriser</code>,<code>TimeSeriesScalerMeanVariance</code> and <code>Flattener</code> classes are some custom made transformers that all employ <code>fit</code>,<code>transform</code> and <code>fit_transform</code> methods.</p>
  
  <p>When I try to <code>ensemble.fit(X, y)</code> fit the whole ensemble I get the error message: </p>
  
  <blockquote>
    <p>ValueError: The estimator list should be a classifier.</p>
  </blockquote>
  
  <p>Which I can understand, as the individual estimators are not specifically classifiers but pipelines. Is there a way to still make it work?</p>