MCPcopy Index your code
hub / github.com/FoundationVision/ByteTrack / set_epoch

Method set_epoch

tutorials/motr/joint.py:72–82  ·  view source on GitHub ↗
(self, epoch)

Source from the content-addressed store, hash-verified

70 # assert len(self.video_dict) <= 300
71
72 def set_epoch(self, epoch):
73 self.current_epoch = epoch
74 if self.sampler_steps is None or len(self.sampler_steps) == 0:
75 # fixed sampling length.
76 return
77
78 for i in range(len(self.sampler_steps)):
79 if epoch >= self.sampler_steps[i]:
80 self.period_idx = i + 1
81 print("set epoch: epoch {} period_idx={}".format(epoch, self.period_idx))
82 self.num_frames_per_batch = self.lengths[self.period_idx]
83
84 def step_epoch(self):
85 # one epoch finishes.

Callers 2

step_epochMethod · 0.95
mainFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected