class_docstr: Base class of Input processor.
class_docstr_tok: ["Base","class","of","Input","processor","."]
docstr: Resize input image and crop it to the self._output dimension.
docstr_tok: ["Resize","input","image","and","crop","it","to","the","self._output","dimension","."]
code: def resize_and_crop_image(
      self, method=tf.image.ResizeMethod.BILINEAR
  ):
      """Resize input image and crop it to the self._output dimension."""
      scaled_image = tf.image.resize(
          self._image,
          [self._scaled_height, self._scaled_width],
          method=method,
      )
      scaled_image = scaled_image[
          self._crop_offset_y : self._crop_offset_y
          + self._output_size[0],
          self._crop_offset_x : self._crop_offset_x
          + self._output_size[1],
          :,
      ]
      output_image = tf.image.pad_to_bounding_box(
          scaled_image, 0, 0, self._output_size[0], self._output_size[1]
      )
      return output_image
  
imports: from absl import logging
  import tensorflow
  import utils
  from pipeline import anchors
  from .None import preprocessor
  from .None import tf_example_decoder
label_desc: Use image node_id 5 for calling the InputProcessor obj's underlying member method code with example usage: obj.resize_and_crop_image(method) and returns: output_image