code: def __getitem__(self, index):
      intrin_path = self.intrins[index]
      example_id = os.path.basename(os.path.dirname(intrin_path))
  
      self.load_example_id(example_id, intrin_path)
      if self.dataset_name == "train":
          frame_idxs = torch.randperm(len(self.all_rgbs[example_id]))[
              : self.imgs_per_obj
          ]
  
          frame_idxs = torch.cat(
              [frame_idxs[: self.cfg.data.input_images], frame_idxs],
              dim=0,
          )
  
      else:
          input_idxs = self.test_input_idxs
  
          frame_idxs = torch.cat(
              [
                  torch.tensor(input_idxs),
                  torch.tensor(
                      [i for i in range(251) if i not in input_idxs]
                  ),
              ],
              dim=0,
          )
  
      images_and_camera_poses = {
          "gt_images": self.all_rgbs[example_id][frame_idxs].clone(),
          "world_view_transforms": self.all_world_view_transforms[
              example_id
          ][frame_idxs],
          "view_to_world_transforms": self.all_view_to_world_transforms[
              example_id
          ][frame_idxs],
          "full_proj_transforms": self.all_full_proj_transforms[
              example_id
          ][frame_idxs],
          "camera_centers": self.all_camera_centers[example_id][
              frame_idxs
          ],
      }
  
      images_and_camera_poses = self.make_poses_relative_to_first(
          images_and_camera_poses
      )
      images_and_camera_poses[
          "source_cv2wT_quat"
      ] = self.get_source_cw2wT(
          images_and_camera_poses["view_to_world_transforms"]
      )
  
      return images_and_camera_poses
  
file_path: splatter-image/scene/srn.py
imports: import glob
  import os
  import numpy
  import torch
  from torch.utils.data import Dataset
  from .dataset_readers import readCamerasFromTxt
  from utils.general_utils import PILtoTorch, matrix_to_quaternion
  from utils.graphics_utils import getWorld2View2, getProjectionMatrix, getView2World
label_desc: Use image node_id 7 for calling the SRNDataset obj's underlying member method code with example usage: obj.__getitem__(index) and returns: images_and_camera_poses