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

Method forward

recipes_source/regional_compilation.py:93–98  ·  view source on GitHub ↗
(self, x)

Source from the content-addressed store, hash-verified

91 self.layers = torch.nn.ModuleList([Layer() for _ in range(64)])
92
93 def forward(self, x):
94 # In regional compilation, the self.linear is outside of the scope of `torch.compile`.
95 x = self.linear(x)
96 for layer in self.layers:
97 x = layer(x)
98 return x
99
100
101####################################################

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected