code: def test_cwise_performance(self):
      repeats = 10
      n = 1024
      x = tf.random.uniform([n, n])
      y = tf.random.uniform([n, n])
      private_x = tfe.define_private_input("server0", lambda: x)
      private_y = tfe.define_private_input("server0", lambda: y)
  
      @tfe.function
      def test_add(input_x, input_y):
          z = input_x + input_y
          return z.reveal().to_native()
  
      @tfe.function
      def test_sub(input_x, input_y):
          z = input_x - input_y
          return z.reveal().to_native()
  
      @tfe.function
      def test_mul(input_x, input_y):
          z = input_x * input_y
          return z.reveal().to_native()
  
      @tfe.function
      def test_add_constant(input_x):
          z = input_x + 1
          return z.reveal().to_native()
  
      @tfe.function
      def test_mul_constant(input_x):
          z = input_x * 2
          return z.reveal().to_native()
  
      Performance.time_log("Add 1st run")
      result = test_add(private_x, private_y)
      np.testing.assert_allclose(result, x + y, rtol=0.0, atol=0.01)
      Performance.time_log("Add 1st run")
  
      Performance.time_log("Add run " + str(repeats) + " rounds")
      for i in range(repeats):
          test_add(private_x, private_y)
      Performance.time_log("Add run " + str(repeats) + " rounds")
  
      Performance.time_log("Sub 1st run")
      result = test_sub(private_x, private_y)
      np.testing.assert_allclose(result, x - y, rtol=0.0, atol=0.01)
      Performance.time_log("Sub 1st run")
  
      Performance.time_log("Sub run " + str(repeats) + " rounds")
      for i in range(repeats):
          test_sub(private_x, private_y)
      Performance.time_log("Sub run " + str(repeats) + " rounds")
  
      Performance.time_log("Mul 1st run")
      result = test_mul(private_x, private_y)
      np.testing.assert_allclose(
          result, tf.multiply(x, y), rtol=0.0, atol=0.01
      )
      Performance.time_log("Mul 1st run")
  
      Performance.time_log("Mul run " + str(repeats) + " rounds")
      for i in range(repeats):
          test_mul(private_x, private_y)
      Performance.time_log("Mul run " + str(repeats) + " rounds")
  
      Performance.time_log("Add const 1st run")
      result = test_add_constant(private_x)
      np.testing.assert_allclose(result, x + 1, rtol=0.0, atol=0.01)
      Performance.time_log("Add const 1st run")
  
      Performance.time_log("Add const run " + str(repeats) + " rounds")
      for i in range(repeats):
          test_add_constant(private_x)
      Performance.time_log("Add const run " + str(repeats) + " rounds")
  
      Performance.time_log("Mul const 1st run")
      result = test_mul_constant(private_x)
      np.testing.assert_allclose(result, x * 2, rtol=0.0, atol=0.01)
      Performance.time_log("Mul const 1st run")
  
      Performance.time_log("Mul const run " + str(repeats) + " rounds")
      for i in range(repeats):
          test_mul_constant(private_x)
      Performance.time_log("Mul const run " + str(repeats) + " rounds")
  
file_path: tf-encrypted/examples/benchmark/operation/op_profile.py
imports: import argparse
  import unittest
  import numpy
  import tensorflow
  import tf_encrypted
  from tf_encrypted.performance import Performance
  from tf_encrypted.protocol import ABY3
  from tf_encrypted.protocol import Pond
  from tf_encrypted.protocol import SecureNN
label_desc: Use image node_id 7 for calling the TestOPProfile obj's underlying member method code with example usage: obj.test_cwise_performance() and returns: z, z, z, z, z