code: def test_indexing(self):
      directory = self.get_tempdir()
      logger = image.ImageLogger(directory, label="foo")
      zeros = np.zeros(shape=(3, 3), dtype=np.uint8)
      logger.write({"img": zeros, "other_img": zeros + 1})
      logger.write({"img": zeros - 1})
      logger.write({"other_img": zeros + 1})
      logger.write({"other_img": zeros + 2})
  
      fnames = sorted(os.listdir(f"{directory}/foo"))
      expected = [
          "img_000000.png",
          "img_000001.png",
          "other_img_000000.png",
          "other_img_000001.png",
          "other_img_000002.png",
      ]
      self.assertEqual(fnames, expected)
  
file_path: acme/acme/utils/loggers/image_test.py
imports: import os
  from acme.testing import test_utils
  from acme.utils.loggers import image
  import numpy
  from PIL import Image
  from absl.testing import absltest
label_desc: Use image node_id 2 for calling the ImageTest obj's underlying member method code with example usage: obj.test_indexing() without return types