CIFAR100C#

class torch_uncertainty.datasets.classification.CIFAR100C(**kwargs)[source]#

The corrupted CIFAR-100-C Dataset.

Parameters:
  • root (str) – Root directory of the datasets.

  • transform (callable, optional) – A function/transform that takes in a PIL image and returns a transformed version. E.g, transforms.RandomCrop. Defaults to None.

  • target_transform (callable, optional) – A function/transform that takes in the target and transforms it. Defaults to None.

  • subset (str) – The subset to use, one of all or the keys in cifarc_subsets.

  • shift_severity (int) – The shift_severity of the corruption, between 1 and 5.

  • download (bool, optional) – If True, downloads the dataset from the internet and puts it in root directory. If dataset is already downloaded, it is not downloaded again. Defaults to False.

  • kwargs – Additional keyword arguments passed to the parent class (CIFAR-10-C).

See also

  • CIFAR10C - The corrupted CIFAR-10-C dataset.

References

[1] Benchmarking neural network robustness to common corruptions and perturbations. Dan Hendrycks and Thomas Dietterich. In ICLR, 2019.