MCPcopy Create free account
hub / github.com/THUDM/LongWriter / _init_weights

Method _init_weights

train/patch/modeling_chatglm.py:584–586  ·  view source on GitHub ↗

Initialize the weights.

(self, module: nn.Module)

Source from the content-addressed store, hash-verified

582 _no_split_modules = ["GLMBlock"]
583
584 def _init_weights(self, module: nn.Module):
585 """Initialize the weights."""
586 return
587
588 def get_masks(self, input_ids, past_key_values, padding_mask=None):
589 batch_size, seq_length = input_ids.shape

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected