code: def testScatterMaxGrad(self):
      x = tf.constant([[1.0, 2.0, 7], [3.0, 4.0, 8.0], [5.0, 6.0, 7.0]])
      idx = tf.constant([1, 0, 1])
      out = mp_ops.scatter_max(x, idx, size=2)
      with self.test_session():
          diff = tf.test.compute_gradient_error(x, [3, 3], out, [2, 3])
          self.assertLess(diff, 1e-4)
  
file_path: euler/tf_euler/python/euler_ops/mp_ops_test.py
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import os
  import tensorflow
  from tf_euler.python.euler_ops import mp_ops
label_desc: Use image node_id 6 for calling the ScatterTest obj's underlying member method code with example usage: obj.testScatterMaxGrad() without return types