TensorFlow Datasets
收藏数据集概述
数据集列表
数据集使用示例
- MNIST 数据集:
-
加载方式: python import tensorflow_datasets as tfds ds_train = tfds.load(mnist, split=train, shuffle_files=True)
-
数据处理: python ds_train = ds_train.shuffle(1000).batch(128).prefetch(10) for features in ds_train.take(1): image, label = features[image], features[label]
-
数据集特性
- 数据集构建器:
-
类:
tfds.core.DatasetBuilder -
使用方法: python mnist_builder = tfds.builder(mnist) mnist_builder.download_and_prepare() ds = mnist_builder.as_dataset(split=train) info = mnist_builder.info
-
数据集信息: python tfds.core.DatasetInfo( name=mnist, version=3.0.1, description=The MNIST database of handwritten digits., homepage=http://yann.lecun.com/exdb/mnist/, features=FeaturesDict({ image: Image(shape=(28, 28, 1), dtype=tf.uint8), label: ClassLabel(shape=(), dtype=tf.int64, num_classes=10), }), total_num_examples=70000, splits={ test: 10000, train: 60000, }, supervised_keys=(image, label), citation="""@article{lecun2010mnist, title={MNIST handwritten digit database}, author={LeCun, Yann and Cortes, Corinna and Burges, CJ}, journal={ATT Labs [Online]. Available: http://yann.lecun.com/exdb/mnist}, volume={2}, year={2010} }""", )
-
数据集版本与性能
- 版本管理: TensorFlow Datasets 数据集版本管理
- 性能建议: TensorFlow Datasets 性能建议
数据集引用
-
引用格式:
@misc{TFDS, title = {{TensorFlow Datasets}, A collection of ready-to-use datasets}, howpublished = {url{https://www.tensorflow.org/datasets}}, }
数据集贡献
- 添加数据集指南: TensorFlow Datasets 添加数据集指南
- 大型数据集添加: 使用 Beam 添加大型数据集




