class_docstr: Resizes images, re-compresses them in JPEG and yields the result.
class_docstr_tok: ["Resizes","images",",","re-compresses","them","in","JPEG","and","yields","the","result","."]
code: def __init__(self, target_pixels, jpeg_quality=72):
      self._target_pixels = target_pixels
      self._jpeg_quality = [int(cv2.IMWRITE_JPEG_QUALITY), jpeg_quality]
      self._images_failed = Metrics.counter(
          self.__class__, "images_failed"
      )
  
imports: import collections
  import csv
  import io
  import json
  import os
  from absl import logging
  import numpy
  from tensorflow_datasets.core.utils.lazy_imports_utils import tensorflow
  import tensorflow_datasets.public_api
label_desc: Use image node_id 1 to create a new ProcessImageFn object from inherited base classes: beam with example: obj = ProcessImageFn(target_pixels, jpeg_quality)