(
self,
motion_file: str,
input_fps: int,
output_fps: int,
device: torch.device,
frame_range: tuple[int, int] | None,
)
| 83 | |
| 84 | class MotionLoader: |
| 85 | def __init__( |
| 86 | self, |
| 87 | motion_file: str, |
| 88 | input_fps: int, |
| 89 | output_fps: int, |
| 90 | device: torch.device, |
| 91 | frame_range: tuple[int, int] | None, |
| 92 | ): |
| 93 | self.motion_file = motion_file |
| 94 | self.input_fps = input_fps |
| 95 | self.output_fps = output_fps |
| 96 | self.input_dt = 1.0 / self.input_fps |
| 97 | self.output_dt = 1.0 / self.output_fps |
| 98 | self.current_idx = 0 |
| 99 | self.device = device |
| 100 | self.frame_range = frame_range |
| 101 | self._load_motion() |
| 102 | self._interpolate_motion() |
| 103 | self._compute_velocities() |
| 104 | |
| 105 | def _load_motion(self): |
| 106 | """Loads the motion from the csv file.""" |
nothing calls this directly
no test coverage detected