MCPcopy Index your code
hub / github.com/pytorch/tutorials / Lambda

Class Lambda

beginner_source/nn_tutorial.py:742–748  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

740# ``Sequential``.
741
742class Lambda(nn.Module):
743 def __init__(self, func):
744 super().__init__()
745 self.func = func
746
747 def forward(self, x):
748 return self.func(x)
749
750
751def preprocess(x):

Callers 1

nn_tutorial.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected