title: Pipeline error: "AttributeError: 'ColumnTransformer' object has no attribute '_feature_names_in'"
body: <p>I am trying to use scikitlearn to predict over new data using a pipeline object I had trained back in February. Since Friday, February 28th, the predict function no longer works for my pipeline object, citing the error:</p>
  
  <pre><code>&gt;&gt;&gt; df = pd.read_csv('test_df_for_example.csv')
  &gt;&gt;&gt; mdl = joblib.load('split_0_model.pkl')
  &gt;&gt;&gt; mdl.predict(df)
  Traceback (most recent call last):
    File "&lt;stdin&gt;", line 1, in &lt;module&gt;
    File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/sklearn/utils/metaestimators.py", line 116, in &lt;lambda&gt;
      out = lambda *args, **kwargs: self.fn(obj, *args, **kwargs)
    File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/sklearn/pipeline.py", line 419, in predict
      Xt = transform.transform(Xt)
    File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/sklearn/compose/_column_transformer.py", line 587, in transform
      self._validate_features(X.shape[1], X_feature_names)
    File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/sklearn/compose/_column_transformer.py", line 411, in _validate_features
      if ((self._feature_names_in is None or feature_names is None)
  AttributeError: 'ColumnTransformer' object has no attribute '_feature_names_in'
  </code></pre>
  
  <p>I am using Microsoft Azure's virtual machines to do this predicting (although the above code I ran on my local computer), so working with the versioning of the modules is difficult, and most of the time I am forced to use the latest versions of packages. I believe this error comes from scikitlearn's new version 0.22.2.post1, which I am using.</p>
  
  <p>I have an example CSV with testing data <a href="https://drive.google.com/open?id=1iS2X1jM8eY246AJ5Eh1nnpwCJmjbilM0" rel="nofollow noreferrer">here</a></p>
  
  <p>The model file pickled with joblib <a href="https://drive.google.com/open?id=13Cz374Uvn-ssGZWGps3MQVzpWjilmNKO" rel="nofollow noreferrer">here</a></p>
  
  <p>And code to reproduce the error <a href="https://drive.google.com/open?id=1iS2X1jM8eY246AJ5Eh1nnpwCJmjbilM0" rel="nofollow noreferrer">here</a></p>
  
  <p>And yaml environment file <a href="https://drive.google.com/open?id=1hJTErtqCT3gNUKdcFeZ7EaUZhHm40Juv" rel="nofollow noreferrer">here</a></p>
  
  <p>Is there any way I can upgrade my model so that this error does not occur?</p>
  
  <p>Thanks!
  Kristine</p>