code: def test_ch_loc():
      """Test raw kit loc."""
      raw_py = read_raw_kit(
          sqd_path, mrk_path, elp_txt_path, hsp_txt_path, stim="<"
      )
      raw_bin = read_raw_fif(data_dir / "test_bin_raw.fif")
  
      ch_py = np.array(
          [ch["loc"] for ch in raw_py._raw_extras[0]["channels"][:160]]
      )
      # ch locs stored as m, not mm
      ch_py[:, :3] *= 1e3
      ch_sns = read_sns(data_dir / "sns.txt")
      assert_array_almost_equal(ch_py, ch_sns, 2)
  
      assert_array_almost_equal(
          raw_py.info["dev_head_t"]["trans"],
          raw_bin.info["dev_head_t"]["trans"],
          4,
      )
      for py_ch, bin_ch in zip(raw_py.info["chs"], raw_bin.info["chs"]):
          if bin_ch["ch_name"].startswith("MEG"):
              # the stored ch locs have more precision than the sns.txt
              assert_array_almost_equal(
                  py_ch["loc"], bin_ch["loc"], decimal=2
              )
  
      # test when more than one marker file provided
      mrks = [mrk_path, mrk2_path, mrk3_path]
      read_raw_kit(
          sqd_path, mrks, elp_txt_path, hsp_txt_path, preload=False
      )
      # this dataset does not have the equivalent set of points
      with raw_bin.info._unlock():
          raw_bin.info["dig"] = raw_bin.info["dig"][:8]
      with raw_py.info._unlock():
          raw_py.info["dig"] = raw_py.info["dig"][:8]
      assert_dig_allclose(raw_py.info, raw_bin.info)
  
imports: from pathlib import Path
  import numpy
  import pytest
  import scipy.io
  from numpy.testing import assert_allclose, assert_array_almost_equal, assert_array_equal, assert_equal
  from scipy import linalg
  import mne
  from mne import Epochs, find_events, pick_types, read_events
  from mne._fiff.constants import FIFF
  from mne.datasets.testing import requires_testing_data
  from mne.io import read_epochs_kit, read_raw_fif, read_raw_kit
  from mne.io.kit.constants import KIT
  from mne.io.kit.coreg import read_sns
  from mne.io.kit.kit import get_kit_info
  from mne.io.tests.test_raw import _test_raw_reader
  from mne.surface import _get_ico_surface
  from mne.transforms import apply_trans
  from mne.utils import assert_dig_allclose
label_desc: Use image node_id 7 for calling a global function with example usage: test_ch_loc() without return types