code: def make_grpc_request_fn(servable_name, server, timeout_secs):
      """Wraps function to make grpc requests with runtime args."""
      stub = _create_stub(server)
  
      def _make_grpc_request(examples):
          """Builds and sends request to TensorFlow model server."""
          request = predict_pb2.PredictRequest()
          request.model_spec.name = servable_name
          request.inputs["input"].CopyFrom(
              tf.make_tensor_proto(
                  [ex.SerializeToString() for ex in examples],
                  shape=[len(examples)],
              )
          )
          response = stub.Predict(request, timeout_secs)
          outputs = tf.make_ndarray(response.outputs["outputs"])
          scores = tf.make_ndarray(response.outputs["scores"])
          assert len(outputs) == len(scores)
          return [
              {  # pylint: disable=g-complex-comprehension
                  "outputs": output,
                  "scores": score,
              }
              for output, score in zip(outputs, scores)
          ]
  
      return _make_grpc_request
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import base64
  import functools
  from googleapiclient import discovery
  import grpc
  import numpy
  from tensor2tensor import problems
  from tensor2tensor.data_generators import text_encoder
  from tensor2tensor.utils import cloud_mlengine
  from tensor2tensor.utils import contrib
  import tensorflow.compat.v1
  from tensorflow_serving.apis import predict_pb2
  from tensorflow_serving.apis import prediction_service_pb2_grpc
label_desc: Use image node_id 5 for calling a global function with example usage: make_grpc_request_fn(servable_name, server, timeout_secs) and returns: _make_grpc_request, unknown