MCPcopy Index your code
hub / github.com/InternLM/InternLM / train

Method train

internlm/core/engine.py:128–131  ·  view source on GitHub ↗

Sets the model to training mode.

(self)

Source from the content-addressed store, hash-verified

126 return success, grad_norm
127
128 def train(self):
129 """Sets the model to training mode."""
130 self.training = True
131 self._model.train()
132
133 def eval(self):
134 """Sets the model to evaluation mode."""

Callers 3

mainFunction · 0.45
evaluate_on_val_dlsFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected