MCPcopy Create free account
hub / github.com/Kaggle/docker-python / forward

Method forward

tests/test_pytorch_lightning.py:40–41  ·  view source on GitHub ↗
(self, x)

Source from the content-addressed store, hash-verified

38 def forward(self, x):
39 return F.relu(self.l1(x.view(x.size(0), -1)))
40
41 def training_step(self, batch, batch_idx):
42 x, y = batch
43 y_hat = self(x)
44 loss = F.cross_entropy(y_hat, y)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected