From 28e4566623b75a6b47adaf5d582825fc7197ae22 Mon Sep 17 00:00:00 2001 From: Olivier Grisel Date: Thu, 26 Aug 2021 14:28:42 +0200 Subject: [PATCH] Missing feature_names_in_ in tf-idf transformer's docstring --- sklearn/feature_extraction/text.py | 6 ++++++ sklearn/tests/test_common.py | 1 - 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/sklearn/feature_extraction/text.py b/sklearn/feature_extraction/text.py index 24d9b07023fd3..c53200c89e3d6 100644 --- a/sklearn/feature_extraction/text.py +++ b/sklearn/feature_extraction/text.py @@ -1486,6 +1486,12 @@ class TfidfTransformer(TransformerMixin, BaseEstimator): .. versionadded:: 1.0 + feature_names_in_ : ndarray of shape (`n_features_in_`,) + Names of features seen during :term:`fit`. Defined only when `X` + has feature names that are all strings. + + .. versionadded:: 1.0 + See Also -------- CountVectorizer : Transforms text into a sparse matrix of n-gram counts. diff --git a/sklearn/tests/test_common.py b/sklearn/tests/test_common.py index ea32a6de37126..1d01bfa0d4333 100644 --- a/sklearn/tests/test_common.py +++ b/sklearn/tests/test_common.py @@ -325,7 +325,6 @@ def test_check_n_features_in_after_fitting(estimator): COLUMN_NAME_MODULES_TO_IGNORE = { "compose", - "feature_extraction", "kernel_approximation", "model_selection", "multioutput",