code: def test_orth_axes():
      # Test for test of orthogality of in, out axis to rest of affine
      # Check 3,3, 2, 3, and that negative values don't confuse
      for aff in (np.eye(4), np.diag([2, 3, 1]), np.eye(4) * -1):
          for i in range(aff.shape[0] - 1):
              assert orth_axes(i, i, aff)
      assert orth_axes(2, 2, np.diag([2, 3, 0, 1]))
      assert not orth_axes(2, 2, np.diag([2, 3, 0, 1]), False)
      aff = np.eye(4)
      assert orth_axes(0, 0, aff)
      aff[0, 1] = 1e-4
      assert not orth_axes(0, 0, aff)
      assert orth_axes(0, 0, aff, tol=2e-4)
      aff[1, 0] = 3e-4
      assert not orth_axes(0, 0, aff)
  
imports: from copy import copy
  from types import SimpleNamespace
  import numpy
  from ..coordinate_map import AffineTransform, AxisError, CoordinateMap, CoordMapMaker, CoordMapMakerError, _as_coordinate_map, _fix0, append_io_dim, axmap, compose, drop_io_dim, equivalent, input_axis_index, io_axis_indices, orth_axes, product, shifted_domain_origin, shifted_range_origin
  from ..coordinate_system import CoordinateSystem, CoordinateSystemError, CoordSysMaker
  import pytest
  from numpy.testing import assert_almost_equal, assert_array_equal
label_desc: Use image node_id 36 for calling a global function with example usage: test_orth_axes() without return types