code: def test_raw_data(self):
      # We pass these raw counts and precision/recall values.
      name = "foo"
      true_positive_counts = [75, 64, 21, 5, 0]
      false_positive_counts = [150, 105, 18, 0, 0]
      true_negative_counts = [0, 45, 132, 150, 150]
      false_negative_counts = [0, 11, 54, 70, 75]
      precision = [0.3333333, 0.3786982, 0.5384616, 1.0, 0.0]
      recall = [1.0, 0.8533334, 0.28, 0.0666667, 0.0]
      num_thresholds = 5
      display_name = "some_raw_values"
      description = "We passed raw values into a summary op."
  
      op = summary.raw_data_op(
          name=name,
          true_positive_counts=tf.constant(true_positive_counts),
          false_positive_counts=tf.constant(false_positive_counts),
          true_negative_counts=tf.constant(true_negative_counts),
          false_negative_counts=tf.constant(false_negative_counts),
          precision=tf.constant(precision),
          recall=tf.constant(recall),
          num_thresholds=num_thresholds,
          display_name=display_name,
          description=description,
      )
      pb_via_op = self.normalize_summary_pb(self.pb_via_op(op))
  
      # Call the corresponding method that is decoupled from TensorFlow.
      pb = self.normalize_summary_pb(
          summary.raw_data_pb(
              name=name,
              true_positive_counts=true_positive_counts,
              false_positive_counts=false_positive_counts,
              true_negative_counts=true_negative_counts,
              false_negative_counts=false_negative_counts,
              precision=precision,
              recall=recall,
              num_thresholds=num_thresholds,
              display_name=display_name,
              description=description,
          )
      )
  
      # The 2 methods above should write summaries with the same data.
      self.assertProtoEquals(pb, pb_via_op)
  
      # Test the metadata.
      summary_metadata = pb.value[0].metadata
      self.assertEqual("some_raw_values", summary_metadata.display_name)
      self.assertEqual(
          "We passed raw values into a summary op.",
          summary_metadata.summary_description,
      )
      self.assertEqual(
          metadata.PLUGIN_NAME, summary_metadata.plugin_data.plugin_name
      )
  
      plugin_data = metadata.parse_plugin_metadata(
          summary_metadata.plugin_data.content
      )
      self.assertEqual(5, plugin_data.num_thresholds)
  
      # Test the summary contents.
      values = tensor_util.make_ndarray(pb.value[0].tensor)
      self.verify_float_arrays_are_equal(
          [
              [75.0, 64.0, 21.0, 5.0, 0.0],  # True positives.
              [150.0, 105.0, 18.0, 0.0, 0.0],  # False positives.
              [0.0, 45.0, 132.0, 150.0, 150.0],  # True negatives.
              [0.0, 11.0, 54.0, 70.0, 75.0],  # False negatives.
              [0.3333333, 0.3786982, 0.5384616, 1.0, 0.0],  # Precision.
              [1.0, 0.8533334, 0.28, 0.0666667, 0.0],  # Recall.
          ],
          values,
      )
  
imports: import numpy
  import tensorflow
  from tensorboard.compat.proto import summary_pb2
  from tensorboard.plugins.pr_curve import metadata
  from tensorboard.plugins.pr_curve import summary
  from tensorboard.util import tensor_util
  from tensorboard.util import test_util
label_desc: Use image node_id 18 for calling the PrCurveTest obj's underlying member method code with example usage: obj.test_raw_data() without return types