Join us at TensorFlow World, Oct 28-31. Use code TF20 for 20% off select passes. Register now

tfds.download.add_checksums_dir

View source

Registers a new checksums dir.

tfds.download.add_checksums_dir(checksums_dir)

This function allow external datasets not present in the tfds repository to define their own checksums_dir containing the dataset downloads checksums.

# Set-up the folder containing the 'my_dataset.txt' checksums.
checksum_dir = os.path.join(os.path.dirname(__file__), 'checksums/')
checksum_dir = os.path.normpath(checksum_dir)

# Add the checksum dir (will be executed when the user import your dataset)
tfds.download.add_checksums_dir(checksum_dir)

class MyDataset(tfds.core.DatasetBuilder):
  ...

Args:

  • checksums_dir: str, checksums dir to add to the registry