Remove scikit-learn html sections
parent
02e131ad04
commit
cc28ec3515
|
@ -70,7 +70,7 @@
|
||||||
"source": [
|
"source": [
|
||||||
"import sklearn\n",
|
"import sklearn\n",
|
||||||
"\n",
|
"\n",
|
||||||
"assert sklearn.__version__ >= \"1.0\""
|
"assert sklearn.__version__ >= \"1.0.1\""
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -1667,18 +1667,6 @@
|
||||||
" FunctionTransformer.__init__ = __init__\n",
|
" FunctionTransformer.__init__ = __init__\n",
|
||||||
" FunctionTransformer.get_feature_names_out = get_feature_names_out\n",
|
" FunctionTransformer.get_feature_names_out = get_feature_names_out\n",
|
||||||
"\n",
|
"\n",
|
||||||
" p = make_pipeline(SimpleImputer(), SimpleImputer())\n",
|
|
||||||
" p.fit_transform(pd.DataFrame({\"A\": [1., 2.], \"B\": [3., 4.]}))\n",
|
|
||||||
" if list(p.get_feature_names_out()) == [\"x0\", \"x1\"]:\n",
|
|
||||||
" print(\"Monkey-patching Pipeline.get_feature_names_out()\")\n",
|
|
||||||
" def get_feature_names_out(self, names=None):\n",
|
|
||||||
" names = default_get_feature_names_out(self, names)\n",
|
|
||||||
" for transformer in self:\n",
|
|
||||||
" names = transformer.get_feature_names_out(names)\n",
|
|
||||||
" return names\n",
|
|
||||||
"\n",
|
|
||||||
" Pipeline.get_feature_names_out = get_feature_names_out\n",
|
|
||||||
"\n",
|
|
||||||
"monkey_patch_get_signature_names_out()"
|
"monkey_patch_get_signature_names_out()"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue