code: def _aspect_preserving_resize(image, resize_min):
      shape = tf.shape(input=image)
      height, width = shape[0], shape[1]
  
      new_height, new_width = _smallest_size_at_least(
          height, width, resize_min
      )
  
      return tf.image.resize(
          image,
          [new_height, new_width],
          method=tf.image.ResizeMethod.BILINEAR,
      )
  
file_path: BigDL/python/orca/example/learn/tf/inception/inception_preprocessing.py
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import tensorflow.compat.v1
  from tensorflow.python.ops import control_flow_ops
  from bigdl.dllib.utils.log4Error import invalidInputError
label_desc: Use image node_id 5 for calling a global function with example usage: _aspect_preserving_resize(image, resize_min) and returns: tf