class_docstr: Constructs a DETR feature extractor.
  
  This feature extractor inherits from [`FeatureExtractionMixin`] which contains most of the main methods. Users
  should refer to this superclass for more information regarding those methods.
  
  
  Args:
      format (`str`, *optional*, defaults to `"coco_detection"`):
          Data format of the annotations. One of "coco_detection" or "coco_panoptic".
      do_resize (`bool`, *optional*, defaults to `True`):
          Whether to resize the input to a certain `size`.
      size (`int`, *optional*, defaults to 800):
          Resize the input to the given size. Only has an effect if `do_resize` is set to `True`. If size is a
          sequence like `(width, height)`, output size will be matched to this. If size is an int, smaller edge of
          the image will be matched to this number. i.e, if `height > width`, then image will be rescaled to `(size *
          height / width, size)`.
      max_size (`int`, *optional*, defaults to 1333):
          The largest size an image dimension can have (otherwise it's capped). Only has an effect if `do_resize` is
          set to `True`.
      do_normalize (`bool`, *optional*, defaults to `True`):
          Whether or not to normalize the input with mean and standard deviation.
      image_mean (`int`, *optional*, defaults to `[0.485, 0.456, 0.406]`):
          The sequence of means for each channel, to be used when normalizing images. Defaults to the ImageNet mean.
      image_std (`int`, *optional*, defaults to `[0.229, 0.224, 0.225]`):
          The sequence of standard deviations for each channel, to be used when normalizing images. Defaults to the
          ImageNet std.
docstr: Normalize the image with a certain mean and std.
  
  If given, also normalize the target bounding boxes based on the size of the image.
docstr_tok: ["Normalize","the","image","with","a","certain","mean","and","std",".","If","given",",","also","normalize","the","target","bounding","boxes","based","on","the","size","of","the","image","."]
code: def _normalize(self, image, mean, std, target=None):
      """
      Normalize the image with a certain mean and std.
  
      If given, also normalize the target bounding boxes based on the size of the image.
      """
  
      image = self.normalize(image, mean=mean, std=std)
      if target is None:
          return image, None
  
      target = target.copy()
      h, w = image.shape[-2:]
  
      if "boxes" in target:
          boxes = target["boxes"]
          boxes = corners_to_center_format(boxes)
          boxes = boxes / np.asarray([w, h, w, h], dtype=np.float32)
          target["boxes"] = boxes
  
      return image, target
  
imports: import io
  import pathlib
  import warnings
  from collections import defaultdict
  from typing import Dict, List, Optional, Set, Tuple, Union
  import numpy
  from PIL import Image
  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 8 for calling the DetrFeatureExtractor obj's underlying member method code with example usage: obj._normalize(image, mean, std, target) and returns: image,  target, image,  None