MNIST 2c2d

class deepobs.pytorch.testproblems.mnist_2c2d.mnist_2c2d(batch_size, l2_reg=None)[source]

DeepOBS test problem class for a two convolutional and two dense layered neural network on MNIST.

The network has been adapted from the TensorFlow tutorial and consists of

  • two conv layers with ReLUs, each followed by max-pooling
  • one fully-connected layers with ReLUs
  • 10-unit output layer with softmax
  • cross-entropy loss
  • No regularization

The weight matrices are initialized with truncated normal (standard deviation of 0.05) and the biases are initialized to 0.05.

Parameters:
  • batch_size (int) -- Batch size to use.
  • l2_reg -- No L2-Regularization (weight decay) is used in this test problem. Defaults to None and any input here is ignored.
set_up()[source]

Sets up the vanilla CNN test problem on MNIST.