MCPcopy
hub / github.com/d2l-ai/d2l-zh / stop

Method stop

d2l/mxnet.py:113–116  ·  view source on GitHub ↗

Stop the timer and record the time in a list.

(self)

Source from the content-addressed store, hash-verified

111 self.tik = time.time()
112
113 def stop(self):
114 """Stop the timer and record the time in a list."""
115 self.times.append(time.time() - self.tik)
116 return self.times[-1]
117
118 def avg(self):
119 """Return the average time."""

Callers 9

train_seq2seqFunction · 0.95
train_recsys_ratingFunction · 0.95
train_ch6Function · 0.45
train_epoch_ch8Function · 0.45
train_ch11Function · 0.45
train_concise_ch11Function · 0.45
__exit__Method · 0.45
train_ch13Function · 0.45
train_rankingFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected