MCPcopy Create free account
hub / github.com/apache/singa / train_one_batch

Method train_one_batch

examples/model_selection/Trails/singa_pkg_code/model.py:222–231  ·  view source on GitHub ↗

Defines the computation performed in every training iteration Should be overridden by all subclasses. Args: *input: the arguments of train_one_batch **kwargs: the keyword arguments of train_one_batch

(self, *input, **kwargs)

Source from the content-addressed store, hash-verified

220 raise NotImplementedError
221
222 def train_one_batch(self, *input, **kwargs):
223 """Defines the computation performed in every training iteration
224
225 Should be overridden by all subclasses.
226
227 Args:
228 *input: the arguments of train_one_batch
229 **kwargs: the keyword arguments of train_one_batch
230 """
231 raise NotImplementedError
232
233 def train(self, mode=True):
234 """Set the model in evaluation mode.

Callers 1

__call__Method · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected