TensorFlow Datasets
https://www.tensorflow.org/datasetsTensorFlow Datasets: a collection of ready-to-use datasets. TensorFlow Datasets is a collection of datasets ready to use, with TensorFlow or other Python ML frameworks, such as Jax. All datasets are exposed as tf.data.Datasets , enabling easy-to-use and high-performance input pipelines. To get started see the guide and our list of datasets .
tf.data.Dataset | TensorFlow Core v2.7.0
www.tensorflow.org › api_docs › pythonThe simplest way to create a dataset is to create it from a python list: dataset = tf.data.Dataset.from_tensor_slices ( [1, 2, 3]) for element in dataset: print (element) tf.Tensor (1, shape= (), dtype=int32) tf.Tensor (2, shape= (), dtype=int32) tf.Tensor (3, shape= (), dtype=int32) To process lines from files, use tf.data.TextLineDataset:
Performance tips | TensorFlow Datasets
www.tensorflow.org › datasets › performancesDec 23, 2021 · As those datasets fit in memory, it is possible to significantly improve the performance by caching or pre-loading the dataset. Note that TFDS automatically caches small datasets (the following section has the details). Caching the dataset. Here is an example of a data pipeline which explicitly caches the dataset after normalizing the images.