MCPcopy Create free account
hub / github.com/kwuking/TimeMixer / _initialize_weights

Method _initialize_weights

layers/Conv_Blocks.py:19–24  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

17 self._initialize_weights()
18
19 def _initialize_weights(self):
20 for m in self.modules():
21 if isinstance(m, nn.Conv2d):
22 nn.init.kaiming_normal_(m.weight, mode='fan_out', nonlinearity='relu')
23 if m.bias is not None:
24 nn.init.constant_(m.bias, 0)
25
26 def forward(self, x):
27 res_list = []

Callers 1

__init__Method · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected