| 17 | |
| 18 | |
| 19 | class FrameSamplerOverfit(FrameSampler[FrameSamplerOverfitCfg]): |
| 20 | def sample( |
| 21 | self, |
| 22 | num_frames_in_video: int, |
| 23 | device: torch.device, |
| 24 | ) -> Int64[Tensor, " frame"]: |
| 25 | start = self.cfg.start or 0 |
| 26 | num_frames = self.cfg.num_frames or num_frames_in_video |
| 27 | step = self.cfg.step or 1 |
| 28 | return torch.arange( |
| 29 | start, |
| 30 | start + num_frames * step, |
| 31 | step, |
| 32 | device=device, |
| 33 | ) |
nothing calls this directly
no outgoing calls
no test coverage detected