| 110 | @flow.unittest.skip_unless_1n1d() |
| 111 | def test_save_state_dict(test_case): |
| 112 | class CustomModule(flow.nn.Module): |
| 113 | def __init__(self): |
| 114 | super().__init__() |
| 115 | self.param1 = flow.nn.Parameter(flow.Tensor(32, 1024, 1024)) |
| 116 | self.param2 = flow.nn.Parameter(flow.Tensor(32, 1024, 1024)) |
| 117 | |
| 118 | def forward(self): |
| 119 | return self.param1 + self.param2 |
| 120 | |
| 121 | m = CustomModule() |
| 122 | res1 = m() |
no outgoing calls