code: def _max_pool_grad(op: ops.Operation, grad):
      filter_width = op.get_attr("filter_width")
      filter_height = op.get_attr("filter_height")
      stride_w = op.get_attr("stride_w")
      stride_h = op.get_attr("stride_h")
      padding = op.get_attr("padding")
      return tf.raw_ops.MaxPoolGrad(
          orig_input=op.inputs[0],
          orig_output=op.outputs[0],
          grad=grad,
          ksize=[1, filter_width, filter_height, 1],
          strides=[1, stride_w, stride_h, 1],
          padding=padding,
          data_format="NHWC",
      )
  
file_path: tensorflow-upstream/tensorflow/compiler/mlir/tfr/examples/mnist/ops_defs.py
imports: import os
  import sys
  from absl import app
  import tensorflow
  from tensorflow.compiler.mlir.tfr.python import composite
  from tensorflow.compiler.mlir.tfr.python.op_reg_gen import gen_register_op
  from tensorflow.compiler.mlir.tfr.python.tfr_gen import tfr_gen_from_module
  from tensorflow.python.framework import ops
  from tensorflow.python.ops import gen_math_ops
  from tensorflow.python.ops import gen_nn_ops
  from tensorflow.python.ops import math_ops
  from tensorflow.python.platform import flags
label_desc: Use image node_id 6 for calling a global function with example usage: _max_pool_grad(op, grad) and returns: tf