code: def test_orient_array():
      x = [5, 7]
      y = [0, 1]
      z = np.array([[0, 1], [2, 3]])
      dims = ("y", "x")
  
      # x and y increasing
      xarr = DataArray(z, coords=dict(x=x, y=y), dims=dims)
      arr = orient_array(xarr)
      assert np.array_equal(arr, z)
  
      # x increasing, y decreasing
      xarr = DataArray(z, coords=dict(x=x, y=y[::-1]), dims=dims)
      arr = orient_array(xarr)
      assert np.array_equal(arr, z[::-1])
  
      # x decreasing, y increasing
      xarr = DataArray(z, coords=dict(x=x[::-1], y=y), dims=dims)
      arr = orient_array(xarr)
      assert np.array_equal(arr, z[:, ::-1])
  
      # x and y decreasing
      xarr = DataArray(z, coords=dict(x=x[::-1], y=y[::-1]), dims=dims)
      arr = orient_array(xarr)
      assert np.array_equal(arr, z[::-1, ::-1])
  
file_path: datashader/datashader/tests/test_utils.py
imports: from __future__ import annotations
  import numpy
  from xarray import DataArray
  from datashader.datashape import dshape
  from datashader.utils import Dispatcher, apply, calc_res, isreal, orient_array
label_desc: Use image node_id 5 for calling a global function with example usage: test_orient_array() without return types