code: def test_png_gamma_correction(test_images: Path):
      # opens the file twice, but touches more parts of the API
      im1 = iio.imread(test_images / "kodim03.png", plugin="pillow")
      im1_meta = iio.immeta(
          test_images / "kodim03.png",
          plugin="pillow",
          exclude_applied=False,
      )
  
      im2 = iio.imread(
          test_images / "kodim03.png",
          plugin="pillow",
          apply_gamma=True,
      )
  
      # Test result depending of application of gamma
      assert im1_meta["gamma"] < 1
      assert im1.mean() < im2.mean()
  
      assert im1.shape == (512, 768, 3)
      assert im1.dtype == "uint8"
      assert im2.shape == (512, 768, 3)
      assert im2.dtype == "uint8"
  
imports: import io
  import os
  from pathlib import Path
  import imageio.v3
  import numpy
  import pytest
  from imageio.core.request import InitializationError, Request
  from imageio.core.v3_plugin_api import PluginV3
  from imageio.plugins.pillow import PillowPlugin
  from PIL import Image, ImageSequence, ImageOps, __version__
label_desc: Use image node_id 8 for calling a global function with example usage: test_png_gamma_correction(test_images) without return types