CIFAR
SplitCIFAR
Bases: Benchmark
SplitCIFAR benchmarks.
Source code in sequel/benchmarks/cifar.py
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 |
|
__init__(num_tasks, batch_size, fixed_class_order=None, is_cifar_100=True, eval_batch_size=None, num_workers=0, pin_memory=True, subset=None)
Inits the SplitCIFAR100/100 class. The is_cifar100
boolean flag denotes which dataset is instantiated.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
num_tasks |
int
|
the number of tasks in the benchmark. Usually 20 for SplitCIFAR100 and 5 for SplitCIFAR10. Must be divisible by the number of classes. |
required |
batch_size |
int
|
The train dataloader batch size. Defaults to 256. |
required |
fixed_class_order |
Optional[List[int]]
|
A list of integers denoting a custom fixed_class_order. If None, the alphabetical order is used. Defaults to None. |
None
|
is_cifar_100 |
bool
|
Boolean denoting whether SplitCIFAR100 or SplitCIFAR10 is selected. Defaults to True. |
True
|
eval_batch_size |
int
|
The validation dataloader batch size. If None, |
None
|
num_workers |
int
|
Dataloader number of workers. Defaults to 0. |
0
|
pin_memory |
bool
|
pin_memory argument for dataloaders. Defaults to True. |
True
|
Source code in sequel/benchmarks/cifar.py
50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 |
|
SplitCIFAR10
Bases: SplitCIFAR
Source code in sequel/benchmarks/cifar.py
120 121 122 123 124 125 126 127 128 |
|
__init__(is_cifar_100=False, *args, **kwargs)
Helper class for SplitCIFAR10. Inherits from SplitCIFAR. Look at the parent class for a description of the class arguments.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
is_cifar_100 |
bool
|
Set to False. |
False
|
Source code in sequel/benchmarks/cifar.py
121 122 123 124 125 126 127 128 |
|
SplitCIFAR100
Bases: SplitCIFAR
Source code in sequel/benchmarks/cifar.py
131 132 133 134 135 136 137 138 139 |
|
__init__(is_cifar_100=True, *args, **kwargs)
Helper class for SplitCIFAR100. Inherits from SplitCIFAR. Look at the parent class for a description of the class arguments.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
is_cifar_100 |
bool
|
Set to True. |
True
|
Source code in sequel/benchmarks/cifar.py
132 133 134 135 136 137 138 139 |
|