code: def center_to_corners_format(x):
      """
      Converts a PyTorch tensor of bounding boxes of center format (center_x, center_y, width, height) to corners format
      (left, top, right, bottom).
      """
      x_center, y_center, width, height = x.unbind(-1)
      boxes = [
          (x_center - 0.5 * width),
          (y_center - 0.5 * height),
          (x_center + 0.5 * width),
          (y_center + 0.5 * height),
      ]
      return torch.stack(boxes, dim=-1)
  
file_path: H2O/h2o_flexgen/benchmark/third_party/transformers/src/transformers/models/owlvit/feature_extraction_owlvit.py
imports: from typing import List, Optional, Union
  import numpy
  from PIL import Image
  from transformers.image_utils import PILImageResampling
  from ...feature_extraction_utils import BatchFeature, FeatureExtractionMixin
  from ...image_utils import ImageFeatureExtractionMixin, is_torch_tensor
  from ...utils import TensorType, is_torch_available, logging
label_desc: Use image node_id 1 for calling a global function with example usage: center_to_corners_format(x) and returns: torch