code: def test_optimize_with_getitem_fusion(getter):
      dsk = {
          "a": "some-array",
          "b": (getter, "a", (slice(10, 20), slice(100, 200))),
          "c": (getter, "b", (5, slice(50, 60))),
      }
  
      result = optimize(dsk, ["c"])
      expected_task = (getter, "some-array", (15, slice(150, 160)))
      assert any(
          _check_get_task_eq(v, expected_task) for v in result.values()
      )
      assert len(result) < len(dsk)
  
imports: from __future__ import annotations
  import pytest
  import numpy
  import dask
  import dask.array
  from dask.array.chunk import getitem
  from dask.array.core import getter
  from dask.array.core import getter_nofancy
  from dask.array.optimization import _is_getter_task, fuse_slice, optimize, optimize_blockwise, optimize_slices
  from dask.array.utils import assert_eq
  from dask.highlevelgraph import HighLevelGraph
  from dask.optimization import SubgraphCallable, fuse
  from dask.utils import SerializableLock
label_desc: Use image node_id 9 for calling a global function with example usage: test_optimize_with_getitem_fusion(getter) without return types