TensorFlow Datasets는 TensorFlow 또는 Jax와 같은 다른 Python ML 프레임워크와 함께 사용할 준비가 된 데이터 세트 컬렉션입니다. 모든 데이터세트는
tf.data.Datasets
로 노출되므로 사용이 간편한 고성능 입력 파이프라인이 가능합니다. 시작하려면 가이드 및 데이터세트 목록을 참조하세요.import tensorflow.compat.v2 as tf import tensorflow_datasets as tfds # Construct a tf.data.Dataset ds = tfds.load('mnist', split='train', shuffle_files=True) # Build your input pipeline ds = ds.shuffle(1024).batch(32).prefetch(tf.data.experimental.AUTOTUNE) for example in ds.take(1): image, label = example["image"], example["label"]