MCPcopy Create free account
hub / github.com/deepspeedai/DeepSpeed / __init__

Method __init__

tests/torch_compile/test_compile.py:41–45  ·  view source on GitHub ↗
(self, *args, **kwargs)

Source from the content-addressed store, hash-verified

39class MyModule(torch.nn.Module):
40
41 def __init__(self, *args, **kwargs) -> None:
42 super().__init__(*args, **kwargs)
43 self.fc0 = torch.nn.Linear(1024, 256, bias=False)
44 self.fc1 = torch.nn.Linear(256, 256, bias=False)
45 self.dropout = torch.nn.Dropout(0.5)
46
47 def forward(self, data, residual):
48 output = residual + self.fc1(self.fc0(self.dropout(data))) * 0.5

Callers

nothing calls this directly

Calls 1

DropoutMethod · 0.80

Tested by

no test coverage detected