mirror of
https://github.com/ArthurDanjou/handson-ml3.git
synced 2026-02-01 20:47:50 +01:00
Fixed sklearn compatibility issue for ch 8 and 9
This commit is contained in:
@@ -773,7 +773,7 @@
|
|||||||
"source": [
|
"source": [
|
||||||
"from sklearn.datasets import fetch_openml\n",
|
"from sklearn.datasets import fetch_openml\n",
|
||||||
"\n",
|
"\n",
|
||||||
"mnist = fetch_openml('mnist_784', version=1)\n",
|
"mnist = fetch_openml('mnist_784', version=1, as_frame=False)\n",
|
||||||
"mnist.target = mnist.target.astype(np.uint8)"
|
"mnist.target = mnist.target.astype(np.uint8)"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -938,7 +938,7 @@
|
|||||||
"import urllib\n",
|
"import urllib\n",
|
||||||
"from sklearn.datasets import fetch_openml\n",
|
"from sklearn.datasets import fetch_openml\n",
|
||||||
"\n",
|
"\n",
|
||||||
"mnist = fetch_openml('mnist_784', version=1)\n",
|
"mnist = fetch_openml('mnist_784', version=1, as_frame=False)\n",
|
||||||
"mnist.target = mnist.target.astype(np.int64)"
|
"mnist.target = mnist.target.astype(np.int64)"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user