MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / Simple

Class Simple

imperative/python/test/integration/test_optimizer.py:28–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

26
27
28class Simple(Module):
29 def __init__(self):
30 super().__init__()
31 self.a = Parameter(1.23, dtype=np.float32)
32
33 def forward(self, x):
34 x = x * self.a
35 return x
36
37
38def _test_optimizer(opt_str, test_case, check_class, update_lr=False):

Callers 1

_test_optimizerFunction · 0.70

Calls

no outgoing calls

Tested by 1

_test_optimizerFunction · 0.56