code: def test_exif_orientation(test_images, tmp_path):
      from PIL.Image import Exif  # type: ignore
  
      im = np.load(test_images / "chelsea.npy")
  
      # original image is has landscape format
      assert im.shape[0] < im.shape[1]
  
      im_flipped = np.rot90(im, 1)
      exif_tag = Exif()
      exif_tag[274] = 6  # Set Orientation to 6
  
      iio.imwrite(
          tmp_path / "chelsea_tagged.png",
          im_flipped,
          plugin="pillow",
          exif=exif_tag,
      )
  
      with iio.imopen(
          tmp_path / "chelsea_tagged.png",
          "r",
          plugin="pillow",
      ) as f:
          im_reloaded = f.read()
          im_meta = f.get_meta()
  
      # ensure raw image is now portrait
      assert im_reloaded.shape[0] > im_reloaded.shape[1]
      # ensure that the Exif tag is set in the file
      assert "Orientation" in im_meta and im_meta["Orientation"] == 6
  
      im_reloaded = iio.imread(
          tmp_path / "chelsea_tagged.png", plugin="pillow", rotate=True
      )
  
      assert np.array_equal(im, im_reloaded)
  
      # apply the transform with Pillow's exif_transpose
      with Image.open(tmp_path / "chelsea_tagged.png") as f:
          im_pillow = np.asarray(ImageOps.exif_transpose(f))
  
      assert np.array_equal(im, im_pillow)
  
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 10 for calling a global function with example usage: test_exif_orientation(test_images, tmp_path) without return types