python - 每次运行 Jupyter Notebook 时,是否必须使用 fetch_openml 重新下载 MNIST?
问题描述
一切都在标题中。我在笔记本中运行以下代码:
from sklearn.datasets import fetch_openml
mnist = fetch_openml('mnist_784', version=1)
但是每次我重新打开我的笔记本时都必须重新获取数据集吗?有没有办法在本地存储数据集?谢谢
解决方案
Scikit-learn
fetchers 有 param data_home
,你可以指定它。它的默认值为None
. 在这种情况下,数据存储在~/scikit_learn_data
子文件夹中。更多参数见fetch_openml?
推荐阅读
- python - pip install indexer 和 python3 -m pip install indexer 出错
- excel - 比较来自 InputBox 的值时类型不匹配
- pyspark - 从 pyspark 中的滞后中找到下一个不同的值
- python - folium美化图标中旋转的动态值
- python - 使用python请求进行路径遍历
- java - 有没有办法改变安卓应用程序的向后兼容性?
- schema - Brickschema 信息
- protocol-buffers - 有没有类似 protobuffer 客户端的邮递员
- python - 如何将文件(csv)从 Angular 传递到 Flask Python?
- java - 是否有自定义 Json 序列化器模式来以不同方式序列化属性,包括属性的键名?