class_docstr: Base dataset for detection.
  
  Args:
      proposal_file (str, optional): Proposals file path. Defaults to None.
      file_client_args (dict): Arguments to instantiate the
          corresponding backend in mmdet <= 3.0.0rc6. Defaults to None.
      backend_args (dict, optional): Arguments to instantiate the
          corresponding backend. Defaults to None.
      return_classes (bool): Whether to return class information
          for open vocabulary-based algorithms. Defaults to False.
      caption_prompt (dict, optional): Prompt for captioning.
          Defaults to None.
class_docstr_tok: ["Base","dataset","for","detection",".","Args",":","proposal_file","(","str",",","optional",")",":","Proposals","file","path",".","Defaults","to","None",".","file_client_args","(","dict",")",":","Arguments","to","instantiate","the","corresponding","backend","in","mmdet","<","=","3.0.0rc6",".","Defaults","to","None",".","backend_args","(","dict",",","optional",")",":","Arguments","to","instantiate","the","corresponding","backend",".","Defaults","to","None",".","return_classes","(","bool",")",":","Whether","to","return","class","information","for","open","vocabulary-based","algorithms",".","Defaults","to","False",".","caption_prompt","(","dict",",","optional",")",":","Prompt","for","captioning",".","Defaults","to","None","."]
docstr: Load proposals from proposals file.
  
  The `proposals_list` should be a dict[img_path: proposals]
  with the same length as `data_list`. And the `proposals` should be
  a `dict` or :obj:`InstanceData` usually contains following keys.
  
      - bboxes (np.ndarry): Has a shape (num_instances, 4),
        the last dimension 4 arrange as (x1, y1, x2, y2).
      - scores (np.ndarry): Classification scores, has a shape
        (num_instance, ).
docstr_tok: ["Load","proposals","from","proposals","file",".","The","`","proposals_list","`","should","be","a","dict","[","img_path",":","proposals","]","with","the","same","length","as","`","data_list","`",".","And","the","`","proposals","`","should","be","a","`","dict","`","or",":","obj",":","`","InstanceData","`","usually","contains","following","keys",".","-","bboxes","(","np.ndarry",")",":","Has","a","shape","(","num_instances",",","4",")",",","the","last","dimension","4","arrange","as","(","x1",",","y1",",","x2",",","y2",")",".","-","scores","(","np.ndarry",")",":","Classification","scores",",","has","a","shape","(","num_instance",",",")","."]
code: def load_proposals(self) -> None:
      """Load proposals from proposals file.
  
      The `proposals_list` should be a dict[img_path: proposals]
      with the same length as `data_list`. And the `proposals` should be
      a `dict` or :obj:`InstanceData` usually contains following keys.
  
          - bboxes (np.ndarry): Has a shape (num_instances, 4),
            the last dimension 4 arrange as (x1, y1, x2, y2).
          - scores (np.ndarry): Classification scores, has a shape
            (num_instance, ).
      """
      # TODO: Add Unit Test after fully support Dump-Proposal Metric
      if not is_abs(self.proposal_file):
          self.proposal_file = osp.join(
              self.data_root, self.proposal_file
          )
      proposals_list = load(
          self.proposal_file, backend_args=self.backend_args
      )
      assert len(self.data_list) == len(proposals_list)
      for data_info in self.data_list:
          img_path = data_info["img_path"]
          # `file_name` is the key to obtain the proposals from the
          # `proposals_list`.
          file_name = osp.join(
              osp.split(osp.split(img_path)[0])[-1],
              osp.split(img_path)[-1],
          )
          proposals = proposals_list[file_name]
          data_info["proposals"] = proposals
  
file_path: mmdetection/mmdet/datasets/base_det_dataset.py
imports: import os.path
  from typing import List, Optional
  from mmengine.dataset import BaseDataset
  from mmengine.fileio import load
  from mmengine.utils import is_abs
  from ..registry import DATASETS
label_desc: Use image node_id 3 for calling the BaseDetDataset obj's underlying member method code with example usage: obj.load_proposals() without return types