8 super(MNIST, self).__init__()
9 self.
conv1 = nn.Conv2d(1, 10, kernel_size=5)
10 self.
conv2 = nn.Conv2d(10, 20, kernel_size=5)
12 self.
fc1 = nn.Linear(320, 50)
13 self.
fc2 = nn.Linear(50, 10)
16 x = F.relu(F.max_pool2d(self.
conv1(x), 2))
19 x = F.relu(self.
fc1(x))
20 x = F.dropout(x, training=self.training)
22 return F.log_softmax(x, dim=1)