code: def get_decode(channels=3):
      """Decode an encoded image string, see tf.io.decode_image."""
  
      def _decode(image):  # pylint: disable=missing-docstring
          # tf.io.decode_image does not set the shape correctly, so we use
          # tf.io.deocde_jpeg, which also works for png, see
          # https://github.com/tensorflow/tensorflow/issues/8551
          return tf.io.decode_jpeg(image, channels=channels)
  
      return _decode
  
imports: from typing import Optional, Tuple
  import numpy
  from scenic.dataset_lib.big_transfer.preprocessing import autoaugment
  from scenic.dataset_lib.big_transfer.preprocessing import utils
  from scenic.dataset_lib.big_transfer.registry import Registry
  import tensorflow.compat.v1
  import tensorflow.compat.v2
  from tensorflow_addons import image
label_desc: Use image node_id 6 for calling a global function with example usage: get_decode(channels) and returns: _decode, tf