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

Method __init__

intermediate_source/torch_export_tutorial.py:66–68  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

64
65class MyModule(torch.nn.Module):
66 def __init__(self):
67 super().__init__()
68 self.lin = torch.nn.Linear(100, 10)
69
70 def forward(self, x, y):
71 return torch.nn.functional.relu(self.lin(x + y), inplace=True)

Callers

nothing calls this directly

Calls 1

__init__Method · 0.45

Tested by

no test coverage detected