code: def image_corruption(
      image,
      label,
      reso,
      image_corrupt_ratio_mean,
      image_corrupt_ratio_stddev,
  ):
      """Randomly drop non-lesion pixels."""
  
      if image_corrupt_ratio_mean < 0.000001 and (
          image_corrupt_ratio_stddev < 0.000001
      ):
          return image
  
      # Corrupt non-lesion region according to keep_mask.
      keep_mask = _gen_rand_mask(
          1 - image_corrupt_ratio_mean,
          image_corrupt_ratio_stddev,
          reso // 3,
          image.shape,
      )
  
      keep_mask = tf.logical_or(tf.greater(label, 1.5), keep_mask)
      image *= tf.cast(keep_mask, tf.float32)
  
      return image
  
file_path: mesh/mesh_tensorflow/experimental/data_aug_lib.py
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import tensorflow.compat.v1
  import tensorflow_probability
  from tensorflow.contrib import image
label_desc: Use image node_id 10 for calling a global function with example usage: image_corruption(image, label, reso, image_corrupt_ratio_mean, image_corrupt_ratio_stddev) and returns: image, image