import tensorflow as tf import tensorflow_datasets as tfds data = [\'David\', \'Tom\', \'Jack\', \'Rose\'] data = tf.data.Dataset.from_tensor_slices(data).prefetch(1)