code: def testFormatFloatOrNone(self):
      extra_digits = 0.12345
      self.assertEqual(
          self.metrics._format_float_or_none(extra_digits), "0.123"
      )
      fewer_digits = 0.1
      self.assertEqual(
          self.metrics._format_float_or_none(fewer_digits), "0.100"
      )
      non_float = ""
      self.assertEqual(
          self.metrics._format_float_or_none(non_float), None
      )
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import collections
  import logging
  import tempfile
  from absl.testing import absltest
  import apache_beam
  from apache_beam.testing.test_pipeline import TestPipeline
  from apache_beam.testing.util import assert_that
  from apache_beam.testing.util import equal_to
  import tensorflow.compat.v1
  from tensorflow_text.tools.wordpiece_vocab import utils
label_desc: Use image node_id 10 for calling the CalculateMetricsTest obj's underlying member method code with example usage: obj.testFormatFloatOrNone() without return types