MCPcopy Create free account
hub / github.com/pytorch/tutorials / forward

Method forward

beginner_source/nn_tutorial.py:707–713  ·  view source on GitHub ↗
(self, xb)

Source from the content-addressed store, hash-verified

705 self.conv3 = nn.Conv2d(16, 10, kernel_size=3, stride=2, padding=1)
706
707 def forward(self, xb):
708 xb = xb.view(-1, 1, 28, 28)
709 xb = F.relu(self.conv1(xb))
710 xb = F.relu(self.conv2(xb))
711 xb = F.relu(self.conv3(xb))
712 xb = F.avg_pool2d(xb, 4)
713 return xb.view(-1, xb.size(1))
714
715lr = 0.1
716

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected