code: def test_create_partition_metrics_for_public_partitions(
      self, is_empty_partition
  ):
      output: metrics.PartitionsInfo = cross_partition_combiners._partition_metrics_public_partitions(
          is_empty_partition
      )
      self.assertTrue(output.public_partitions)
      self.assertEqual(output.num_non_public_partitions, 0)
      self.assertEqual(
          output.num_dataset_partitions, 0 if is_empty_partition else 1
      )
      self.assertEqual(
          output.num_empty_partitions, 1 if is_empty_partition else 0
      )
  
imports: from absl.testing import absltest
  from absl.testing import parameterized
  import dataclasses
  import math
  from unittest import mock
  from unittest.mock import patch
  from analysis import metrics
  from analysis import cross_partition_combiners
  import pipeline_dp
label_desc: Use image node_id 2 for calling the PerPartitionToCrossPartitionMetrics obj's underlying member method code with example usage: obj.test_create_partition_metrics_for_public_partitions(is_empty_partition) without return types