MCPcopy Create free account
hub / github.com/AIS-SNU/Smart-Infinity / init_method_normal

Function init_method_normal

DeepSpeedExample/megatron/core/utils.py:155–161  ·  view source on GitHub ↗

Init method based on N(0, sigma).

(sigma)

Source from the content-addressed store, hash-verified

153 tensor.data = new_data_tensor
154
155def init_method_normal(sigma):
156 """Init method based on N(0, sigma)."""
157
158 def init_(tensor):
159 return torch.nn.init.normal_(tensor, mean=0.0, std=sigma)
160
161 return init_
162
163
164def scaled_init_method_normal(sigma, num_layers):

Callers 1

__post_init__Method · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected