MCPcopy Create free account
hub / github.com/tdrussell/diffusion-pipe / init_weights

Method init_weights

models/cosmos_predict2_modeling.py:830–832  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

828 self.init_weights()
829
830 def init_weights(self) -> None:
831 std = 1.0 / math.sqrt(self.dim)
832 torch.nn.init.trunc_normal_(self.proj[1].weight, std=std, a=-3 * std, b=3 * std)
833
834 def forward(self, x: torch.Tensor) -> torch.Tensor:
835 """

Callers 1

__init__Method · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected