code: def testInfNanMonitorOnExecutionUnderFullTensorModeWorks(
      self,
      tensor_value,
      dtype,
      expected_size,
      expected_num_neg_inf,
      expected_num_pos_inf,
      expected_num_nan,
  ):
      mock_reader = test.mock.MagicMock()
      mock_reader.execution_to_tensor_values.return_value = [
          np.array([[0.0, -1.0, 1.0]]),
          np.array(tensor_value, dtype=dtype),
      ]
      monitor = debug_events_monitors.InfNanMonitor(mock_reader)
      execution_digest = debug_events_reader.ExecutionDigest(
          1234,
          1,
          "__inference_bar_function_1234",
          output_tensor_device_ids=[0, 1],
      )
      execution = debug_events_reader.Execution(
          execution_digest,
          "worker01",
          ["a1", "b2", "e3"],
          debug_event_pb2.TensorDebugMode.FULL_TENSOR,
          graph_id=None,
          input_tensor_ids=[12, 34],
          output_tensor_ids=[56, 78],
      )
      monitor.on_execution(70, execution)
  
      if (
          expected_num_neg_inf
          or expected_num_pos_inf
          or expected_num_nan
      ):
          self.assertLen(monitor.alerts(), 1)
          alert = monitor.alerts()[0]
          self.assertEqual(alert.wall_time, 1234)
          self.assertEqual(
              alert.op_type, "__inference_bar_function_1234"
          )
          self.assertEqual(alert.output_slot, 1)
          self.assertEqual(alert.size, expected_size)
          self.assertEqual(alert.num_neg_inf, expected_num_neg_inf)
          self.assertEqual(alert.num_pos_inf, expected_num_pos_inf)
          self.assertEqual(alert.num_nan, expected_num_nan)
          self.assertEqual(alert.execution_index, 70)
          self.assertIsNone(alert.graph_execution_trace_index, 70)
      else:
          self.assertEmpty(monitor.alerts())
  
imports: from absl.testing import parameterized
  import numpy
  from tensorflow.core.protobuf import debug_event_pb2
  from tensorflow.python.debug.lib import debug_events_monitors
  from tensorflow.python.debug.lib import debug_events_reader
  from tensorflow.python.debug.lib import dumping_callback
  from tensorflow.python.debug.lib import dumping_callback_test_lib
  from tensorflow.python.eager import def_function
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import test_util
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import math_ops
  from tensorflow.python.platform import googletest
  from tensorflow.python.platform import test
label_desc: Use image node_id 5 for calling the InfNanMonitorTest obj's underlying member method code with example usage: obj.testInfNanMonitorOnExecutionUnderFullTensorModeWorks(tensor_value, dtype, expected_size, expected_num_neg_inf, expected_num_pos_inf, expected_num_nan) without return types