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

Method __init__

beginner_source/hyperparameter_tuning_tutorial.py:108–115  ·  view source on GitHub ↗
(self, l1=120, l2=84)

Source from the content-addressed store, hash-verified

106
107class Net(nn.Module):
108 def __init__(self, l1=120, l2=84):
109 super().__init__()
110 self.conv1 = nn.Conv2d(3, 6, 5)
111 self.pool = nn.MaxPool2d(2, 2)
112 self.conv2 = nn.Conv2d(6, 16, 5)
113 self.fc1 = nn.Linear(16 * 5 * 5, l1)
114 self.fc2 = nn.Linear(l1, l2)
115 self.fc3 = nn.Linear(l2, 10)
116
117 def forward(self, x):
118 x = self.pool(F.relu(self.conv1(x)))

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected