CIFAR-100 VGG16

class deepobs.cifar100.cifar100_vgg16.set_up(batch_size=128, weight_decay=0.0005)[source]

Class providing the functionality for the VGG 16 architecture on CIFAR-100. The CIFAR-100 images are resized to 224 by 224 to fit the input dimension of the original VGG network, which was designed for ImageNet.

Details about the architecture can be found in the original paper. VGG 16 consists of 16 weight layers, of mostly convolutions. The model uses cross-entroy loss. A weight decay is used on the weights (but not the biases) which defaults to 5e-4.

Basis data augmentation (random crop, left-right flip, lighting augmentation) is done on the training images.

Parameters:
  • batch_size (int) -- Batch size of the data points. Defaults to 128.
  • weight_decay (float) -- Weight decay factor. In this model weight decay is applied to the weights, but not the biases. Defaults to 5e-4.
data_loading

Data loading class for CIFAR-100, cifar100_input.data_loading.

Type:deepobs.data_loading
losses

Tensor of size batch_size containing the individual losses per data point.

Type:tf.Tensor
accuracy

Tensor containing the accuracy of the model.

Type:tf.Tensor
train_init_op

A TensorFlow operation to be performed before starting every training epoch.

Type:tf.Operation
train_eval_init_op

A TensorFlow operation to be performed before starting every training eval epoch.

Type:tf.Operation
test_init_op

A TensorFlow operation to be performed before starting every test evaluation phase.

Type:tf.Operation
get()[source]

Returns the losses and the accuray of the model.

Returns:Tupel consisting of the losses and the accuracy.
Return type:tupel
set_up(weight_decay)[source]

Sets up the test problem.

Parameters:weight_decay (float) -- Weight decay factor, which is only applied to the weights and not the biases.
Returns:Tupel consisting of the losses and the accuracy.
Return type:tupel