class_docstr: OpenImages evaluation metric.
  
  Evaluate detection mAP for OpenImages. Please refer to
  https://storage.googleapis.com/openimages/web/evaluation.html for more
  details.
  
  Args:
      iou_thrs (float or List[float]): IoU threshold. Defaults to 0.5.
      ioa_thrs (float or List[float]): IoA threshold. Defaults to 0.5.
      scale_ranges (List[tuple], optional): Scale ranges for evaluating
          mAP. If not specified, all bounding boxes would be included in
          evaluation. Defaults to None
      use_group_of (bool): Whether consider group of groud truth bboxes
          during evaluating. Defaults to True.
      get_supercategory (bool): Whether to get parent class of the
          current class. Default: True.
      filter_labels (bool): Whether filter unannotated classes.
          Default: True.
      collect_device (str): Device name used for collecting results from
          different ranks during distributed training. Must be 'cpu' or
          'gpu'. Defaults to 'cpu'.
      prefix (str, optional): The prefix that will be added in the metric
          names to disambiguate homonymous metrics of different evaluators.
          If prefix is not provided in the argument, self.default_prefix
          will be used instead. Defaults to None.
class_docstr_tok: ["OpenImages","evaluation","metric",".","Evaluate","detection","mAP","for","OpenImages",".","Please","refer","to","https",":","\/\/storage.googleapis.com\/openimages\/web\/evaluation.html","for","more","details",".","Args",":","iou_thrs","(","float","or","List","[","float","]",")",":","IoU","threshold",".","Defaults","to","0.5.","ioa_thrs","(","float","or","List","[","float","]",")",":","IoA","threshold",".","Defaults","to","0.5.","scale_ranges","(","List","[","tuple","]",",","optional",")",":","Scale","ranges","for","evaluating","mAP",".","If","not","specified",",","all","bounding","boxes","would","be","included","in","evaluation",".","Defaults","to","None","use_group_of","(","bool",")",":","Whether","consider","group","of","groud","truth","bboxes","during","evaluating",".","Defaults","to","True",".","get_supercategory","(","bool",")",":","Whether","to","get","parent","class","of","the","current","class",".","Default",":","True",".","filter_labels","(","bool",")",":","Whether","filter","unannotated","classes",".","Default",":","True",".","collect_device","(","str",")",":","Device","name","used","for","collecting","results","from","different","ranks","during","distributed","training",".","Must","be","'cpu","'","or","'gpu","'",".","Defaults","to","'cpu","'",".","prefix","(","str",",","optional",")",":","The","prefix","that","will","be","added","in","the","metric","names","to","disambiguate","homonymous","metrics","of","different","evaluators",".","If","prefix","is","not","provided","in","the","argument",",","self.default_prefix","will","be","used","instead",".","Defaults","to","None","."]
code: def __init__(
      self,
      iou_thrs: Union[float, List[float]] = 0.5,
      ioa_thrs: Union[float, List[float]] = 0.5,
      scale_ranges: Optional[List[tuple]] = None,
      use_group_of: bool = True,
      get_supercategory: bool = True,
      filter_labels: bool = True,
      collect_device: str = "cpu",
      prefix: Optional[str] = None,
  ) -> None:
      super().__init__(collect_device=collect_device, prefix=prefix)
      self.iou_thrs = (
          [iou_thrs] if isinstance(iou_thrs, float) else iou_thrs
      )
      self.ioa_thrs = (
          [ioa_thrs]
          if (isinstance(ioa_thrs, float) or ioa_thrs is None)
          else ioa_thrs
      )
      assert isinstance(self.iou_thrs, list) and isinstance(
          self.ioa_thrs, list
      )
      assert len(self.iou_thrs) == len(self.ioa_thrs)
  
      self.scale_ranges = scale_ranges
      self.use_group_of = use_group_of
      self.get_supercategory = get_supercategory
      self.filter_labels = filter_labels
  
file_path: mmdetection/mmdet/evaluation/metrics/openimages_metric.py
imports: import copy
  from collections import OrderedDict
  from typing import List, Optional, Sequence, Union
  import numpy
  from mmengine.evaluator import BaseMetric
  from mmengine.logging import MMLogger, print_log
  from mmdet.registry import METRICS
  from ..functional import eval_map
label_desc: Use image node_id 1 to create a new OpenImagesMetric object from inherited base classes: BaseMetric with example: obj = OpenImagesMetric(iou_thrs, ioa_thrs, scale_ranges, use_group_of, get_supercategory, filter_labels, collect_device, prefix)