yamle.data.classification module#
- class yamle.data.classification.TorchvisionClassificationDataModule(dataset, pad_to_32=False, *args, **kwargs)[source]#
Bases:
VisionClassificationDataModuleData module for the torchvision datasets.
- Parameters:
- outputs_dtype = torch.int64#
- class yamle.data.classification.TinyImageNetClassificationDataModule(*args, **kwargs)[source]#
Bases:
TorchvisionClassificationDataModuleData module for the TinyImageNet dataset.
- inputs_dim = (3, 64, 64)#
- outputs_dim = 200#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.4802, 0.4481, 0.3975)#
-
std:
Tuple[float,...] = (0.2302, 0.2265, 0.2262)#
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.TorchvisionClassificationDataModuleMNIST(*args, **kwargs)[source]#
Bases:
TorchvisionClassificationDataModuleData module for the MNIST dataset.
- inputs_dim = (1, 28, 28)#
- outputs_dim = 10#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.1307,)#
-
std:
Tuple[float,...] = (0.3081,)#
- prepare_data()[source]#
Download and prepare the data, the data is stored in self._train_dataset, self._validation_dataset and self._test_dataset.
- Return type:
None
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.TorchvisionClassificationDataModuleFashionMNIST(*args, **kwargs)[source]#
Bases:
TorchvisionClassificationDataModuleData module for the FashionMNIST dataset.
- inputs_dim = (1, 28, 28)#
- outputs_dim = 10#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.286,)#
-
std:
Tuple[float,...] = (0.353,)#
- prepare_data()[source]#
Download and prepare the data, the data is stored in self._train_dataset, self._validation_dataset and self._test_dataset.
- Return type:
None
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.TorchvisionClassificationDataModuleSVHN(*args, **kwargs)[source]#
Bases:
TorchvisionClassificationDataModuleData module for the SVHN dataset.
- inputs_dim = (3, 32, 32)#
- outputs_dim = 10#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.4377, 0.4438, 0.4728)#
-
std:
Tuple[float,...] = (0.198, 0.201, 0.197)#
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.TorchvisionClassificationDataModuleCIFAR10(*args, **kwargs)[source]#
Bases:
TorchvisionClassificationDataModuleData module for the CIFAR10 dataset.
- inputs_dim = (3, 32, 32)#
- outputs_dim = 10#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.4914, 0.4822, 0.4465)#
-
std:
Tuple[float,...] = (0.2023, 0.1994, 0.201)#
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.TorchvisionClassificationDataModuleCIFAR3(indices, *args, **kwargs)[source]#
Bases:
TorchvisionClassificationDataModuleData module for the CIFAR3 dataset.
- inputs_dim = (3, 32, 32)#
- outputs_dim = 3#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.4914, 0.4822, 0.4465)#
-
std:
Tuple[float,...] = (0.2023, 0.1994, 0.201)#
- static add_specific_args(parent_parser)[source]#
Add dataset specific arguments to the parser.
- Return type:
ArgumentParser
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.TorchvisionClassificationDataModuleCIFAR5(indices, *args, **kwargs)[source]#
Bases:
TorchvisionClassificationDataModuleData module for the CIFAR5 dataset.
- inputs_dim = (3, 32, 32)#
- outputs_dim = 5#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.4914, 0.4822, 0.4465)#
-
std:
Tuple[float,...] = (0.2023, 0.1994, 0.201)#
- static add_specific_args(parent_parser)[source]#
Add dataset specific arguments to the parser.
- Return type:
ArgumentParser
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.TorchvisionClassificationDataModuleCIFAR100(*args, **kwargs)[source]#
Bases:
TorchvisionClassificationDataModuleData module for the CIFAR100 dataset.
- inputs_dim = (3, 32, 32)#
- outputs_dim = 100#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.4914, 0.4822, 0.4465)#
-
std:
Tuple[float,...] = (0.2023, 0.1994, 0.201)#
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.MedMNISTClassificationDataModule(dataset, pad_to_32=True, *args, **kwargs)[source]#
Bases:
VisionClassificationDataModuleData module for the MedMNIST dataset.
- Parameters:
- outputs_dtype = torch.int64#
- class yamle.data.classification.PneumoniaMNISTClassificationDataModule(*args, **kwargs)[source]#
Bases:
MedMNISTClassificationDataModuleData module for the PneumoniaMNIST dataset.
- inputs_dim = (1, 28, 28)#
- outputs_dim = 2#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.5404,)#
-
std:
Tuple[float,...] = (0.2824,)#
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.BreastMNISTClassificationDataModule(*args, **kwargs)[source]#
Bases:
MedMNISTClassificationDataModuleData module for the BreastMNIST dataset.
- inputs_dim = (1, 28, 28)#
- outputs_dim = 2#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.3304,)#
-
std:
Tuple[float,...] = (0.2057,)#
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.DermaMNISTClassificationDataModule(*args, **kwargs)[source]#
Bases:
MedMNISTClassificationDataModuleData module for the DermaMNIST dataset.
- inputs_dim = (3, 28, 28)#
- outputs_dim = 7#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.7637, 0.5383, 0.5615)#
-
std:
Tuple[float,...] = (0.1371, 0.154, 0.169)#
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.BloodMNISTClassificationDataModule(*args, **kwargs)[source]#
Bases:
MedMNISTClassificationDataModuleData module for the BloodMNIST dataset.
- inputs_dim = (3, 28, 28)#
- outputs_dim = 8#
- targets_dim = 1#
-
mean:
Tuple[float,...] = (0.7943, 0.6596, 0.6962)#
-
std:
Tuple[float,...] = (0.2156, 0.2415, 0.1179)#
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.ToyTwoMoonsClassificationDataModule(noise, num_samples, *args, **kwargs)[source]#
Bases:
BaseDataModuleData module for a toy classification problem between data coming from 2 classes with 2 features.
- Parameters:
- inputs_dim = (2,)#
- outputs_dim = 2#
- targets_dim = 1#
- task = 'classification'#
- inputs_dtype = torch.float32#
- outputs_dtype = torch.int64#
- class yamle.data.classification.ToyTwoCirclesClassificationDataModule(*args, **kwargs)[source]#
Bases:
ToyTwoMoonsClassificationDataModuleToy two ovals classification dataset.
- available_transforms: List[str]#
- available_test_augmentations: List[str]#
- test_augmentations: List[str]#
- class yamle.data.classification.UCIClassificationDataModule(dataset, *args, **kwargs)[source]#
Bases:
RealWorldClassificationDataModuleData module for the UCI classification datasets.
- Currently supports the following datasets:
Breast Cancer
Adult income
Car evaluation
Credit default
Dermatology
- Parameters:
dataset¶ (str) – Name of the dataset to use.
- class yamle.data.classification.BreastCancerUCIClassificationDataModule(*args, **kwargs)[source]#
Bases:
UCIClassificationDataModuleData module for the Breast Cancer dataset.
- outputs_dim = 2#
- outputs_dtype = torch.int64#
- inputs_dim = (9,)#
- inputs_dtype = torch.float32#
- task = 'classification'#
- class yamle.data.classification.AdultIncomeUCIClassificationDataModule(*args, **kwargs)[source]#
Bases:
UCIClassificationDataModuleData module for the Adult Income dataset.
- outputs_dim = 2#
- outputs_dtype = torch.int64#
- inputs_dim = (108,)#
- inputs_dtype = torch.float32#
- task = 'classification'#
- class yamle.data.classification.CarEvaluationUCIClassificationDataModule(*args, **kwargs)[source]#
Bases:
UCIClassificationDataModuleData module for the Car Evaluation dataset.
- outputs_dim = 4#
- outputs_dtype = torch.int64#
- inputs_dim = (21,)#
- inputs_dtype = torch.float32#
- task = 'classification'#
- class yamle.data.classification.CreditUCIClassificationDataModule(*args, **kwargs)[source]#
Bases:
UCIClassificationDataModuleData module for the Credit Default dataset.
- outputs_dim = 2#
- outputs_dtype = torch.int64#
- inputs_dim = (23,)#
- inputs_dtype = torch.float32#
- task = 'classification'#
- class yamle.data.classification.DermatologyUCIClassificationDataModule(*args, **kwargs)[source]#
Bases:
UCIClassificationDataModuleData module for the Dermatology dataset.
- outputs_dim = 6#
- outputs_dtype = torch.int64#
- inputs_dim = (34,)#
- inputs_dtype = torch.float32#
- task = 'classification'#