MCPcopy Create free account
hub / github.com/Robbyant/lingbot-map / load_frame_data

Method load_frame_data

benchmark/datasets/vbr.py:89–104  ·  view source on GitHub ↗
(self, scene: str, frame_id: int)

Source from the content-addressed store, hash-verified

87 return list(range(len(data['rgb_files'])))
88
89 def load_frame_data(self, scene: str, frame_id: int) -> Dict[str, Any]:
90 data = self._load_scene_data(scene)
91 rgb_path = data['rgb_files'][frame_id]
92 rgb = np.array(Image.open(rgb_path).convert('RGB'), dtype=np.uint8)
93
94 pose = data['poses_by_frame'].get(frame_id)
95 intrinsics = data['intrinsics'].copy()
96
97 if self.target_size is not None:
98 rgb, intrinsics = self._cover_fit_center_crop(rgb, intrinsics)
99
100 return {
101 'rgb': rgb,
102 'pose': pose,
103 'intrinsics': intrinsics,
104 }
105
106 def _cover_fit_center_crop(
107 self, rgb: np.ndarray, intrinsics: np.ndarray

Callers

nothing calls this directly

Calls 3

_load_scene_dataMethod · 0.95
copyMethod · 0.45

Tested by

no test coverage detected