code: def _get_params(mode, params):
      """Returns the params defined by the above constants."""
      params = params or {}
      if mode == tf_estimator.ModeKeys.TRAIN:
          num_shuffles = params.get(_NUM_SHUFFLES_TRAIN, None)
      elif mode == tf_estimator.ModeKeys.EVAL:
          num_shuffles = params.get(_NUM_SHUFFLES_EVAL, None)
      elif mode == tf_estimator.ModeKeys.PREDICT:
          num_shuffles = params.get(_NUM_SHUFFLES_PREDICT, None)
      else:
          raise ValueError("Invalid mode: {}.".format(mode))
      return num_shuffles
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import abc
  import six
  import tensorflow
  from tensorflow import estimator
  from tensorflow.python.util import function_utils
  from tensorflow_ranking.python import feature
  from tensorflow_ranking.python import utils
label_desc: Use image node_id 1 for calling a global function with example usage: _get_params(mode, params) and returns: num_shuffles