Silence gelsd warning
parent
de9f490bc3
commit
9367c6ef42
|
@ -70,7 +70,7 @@
|
||||||
"\n",
|
"\n",
|
||||||
"# Ignore useless warnings (see SciPy issue #5998)\n",
|
"# Ignore useless warnings (see SciPy issue #5998)\n",
|
||||||
"import warnings\n",
|
"import warnings\n",
|
||||||
"warnings.filterwarnings(action=\"ignore\", module=\"scipy\", message=\"internal gelsd\")"
|
"warnings.filterwarnings(action=\"ignore\", message=\"^internal gelsd\")"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -983,14 +983,21 @@
|
||||||
"**Warning**: earlier versions of the book applied different transformations to different columns using a solution based on a `DataFrameSelector` transformer and a `FeatureUnion` (see below). It is now preferable to use the `ColumnTransformer` class that will be introduced in Scikit-Learn 0.20. For now we import it from `future_encoders.py`, but when Scikit-Learn 0.20 is released, you can import it from `sklearn.compose` instead:"
|
"**Warning**: earlier versions of the book applied different transformations to different columns using a solution based on a `DataFrameSelector` transformer and a `FeatureUnion` (see below). It is now preferable to use the `ColumnTransformer` class that will be introduced in Scikit-Learn 0.20. For now we import it from `future_encoders.py`, but when Scikit-Learn 0.20 is released, you can import it from `sklearn.compose` instead:"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"cell_type": "code",
|
||||||
|
"execution_count": 71,
|
||||||
|
"metadata": {},
|
||||||
|
"outputs": [],
|
||||||
|
"source": [
|
||||||
|
"from future_encoders import ColumnTransformer"
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": 72,
|
"execution_count": 72,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"from future_encoders import ColumnTransformer\n",
|
|
||||||
"\n",
|
|
||||||
"num_attribs = list(housing_num)\n",
|
"num_attribs = list(housing_num)\n",
|
||||||
"cat_attribs = [\"ocean_proximity\"]\n",
|
"cat_attribs = [\"ocean_proximity\"]\n",
|
||||||
"\n",
|
"\n",
|
||||||
|
|
Loading…
Reference in New Issue