class_docstr: A bounding box in VOC detection format.
  
  Args:
      xmin: the top-left x coordinate
      ymin: the top-left y coordinate
      xmax: the bottom-right x coordinate
      ymax: the bottom-right y coordinate
class_docstr_tok: ["A","bounding","box","in","VOC","detection","format",".","Args",":","xmin",":","the","top-left","x","coordinate","ymin",":","the","top-left","y","coordinate","xmax",":","the","bottom-right","x","coordinate","ymax",":","the","bottom-right","y","coordinate"]
docstr: Returns a representation of the bounding box suitable for storing in
  the ``bounding_box`` field of a
  :class:`fiftyone.core.labels.Detection`.
  
  Args:
      frame_size: the ``(width, height)`` of the image
  
  Returns:
      ``[x-top-left, y-top-left, width, height]``
docstr_tok: ["Returns","a","representation","of","the","bounding","box","suitable","for","storing","in","the","``","bounding_box","``","field","of","a",":","class",":","`","fiftyone.core.labels.Detection","`",".","Args",":","frame_size",":","the","``","(","width",",","height",")","``","of","the","image","Returns",":","``","[","x-top-left",",","y-top-left",",","width",",","height","]","``"]
code: def to_detection_format(self, frame_size):
      """Returns a representation of the bounding box suitable for storing in
      the ``bounding_box`` field of a
      :class:`fiftyone.core.labels.Detection`.
  
      Args:
          frame_size: the ``(width, height)`` of the image
  
      Returns:
          ``[x-top-left, y-top-left, width, height]``
      """
      width, height = frame_size
      x = self.xmin / width
      y = self.ymin / height
      w = (self.xmax - self.xmin) / width
      h = (self.ymax - self.ymin) / height
      return [x, y, w, h]
  
imports: import logging
  import os
  import jinja2
  import eta.core.utils
  import fiftyone.constants
  import fiftyone.core.labels
  import fiftyone.core.metadata
  import fiftyone.core.storage
  import fiftyone.core.utils
  import fiftyone.utils.data
label_desc: Use image node_id 4 for calling the VOCBoundingBox obj's underlying member method code with example usage: obj.to_detection_format(frame_size) and returns: list