code: def get_phantom_dipoles(kind="vectorview"):
      """Get standard phantom dipole locations and orientations.
  
      Parameters
      ----------
      kind : str
          Get the information for the given system:
  
              ``vectorview`` (default)
                The Neuromag VectorView phantom.
              ``otaniemi``
                The older Neuromag phantom used at Otaniemi.
              ``oyama``
                The phantom from :footcite:`OyamaEtAl2015`.
  
          .. versionchanged:: 1.6
             Support added for ``'oyama'``.
  
      Returns
      -------
      pos : ndarray, shape (n_dipoles, 3)
          The dipole positions.
      ori : ndarray, shape (n_dipoles, 3)
          The dipole orientations.
  
      See Also
      --------
      mne.datasets.fetch_phantom
  
      Notes
      -----
      The Elekta phantoms have a radius of 79.5mm, and HPI coil locations
      in the XY-plane at the axis extrema (e.g., (79.5, 0), (0, -79.5), ...).
  
      References
      ----------
      .. footbibliography::
      """
      _validate_type(kind, str, "kind")
      _check_option("kind", kind, ["vectorview", "otaniemi", "oyama"])
      if kind == "vectorview":
          # these values were pulled from a scanned image provided by
          # Elekta folks
          a = np.array([59.7, 48.6, 35.8, 24.8, 37.2, 27.5, 15.8, 7.9])
          b = np.array([46.1, 41.9, 38.3, 31.5, 13.9, 16.2, 20.0, 19.3])
          x = np.concatenate((a, [0] * 8, -b, [0] * 8))
          y = np.concatenate(([0] * 8, -a, [0] * 8, b))
          c = [22.9, 23.5, 25.5, 23.1, 52.0, 46.4, 41.0, 33.0]
          d = [44.4, 34.0, 21.6, 12.7, 62.4, 51.5, 39.1, 27.9]
          z = np.concatenate((c, c, d, d))
          signs = ([1, -1] * 4 + [-1, 1] * 4) * 2
      elif kind == "otaniemi":
          # these values were pulled from an Neuromag manual
          # (NM20456A, 13.7.1999, p.65)
          a = np.array([56.3, 47.6, 39.0, 30.3])
          b = np.array([32.5, 27.5, 22.5, 17.5])
          c = np.zeros(4)
          x = np.concatenate((a, b, c, c, -a, -b, c, c))
          y = np.concatenate((c, c, -a, -b, c, c, b, a))
          z = np.concatenate((b, a, b, a, b, a, a, b))
          signs = [-1] * 8 + [1] * 16 + [-1] * 8
      else:
          assert kind == "oyama"
          xyz = np.fromstring(
              _OYAMA.strip().replace("\n", " "), sep=" "
          ).reshape(25, 3)
          xyz = np.repeat(xyz, 2, axis=0)
          x, y, z = xyz.T
          signs = [1] * 50
      pos = np.vstack((x, y, z)).T / 1000.0
      # For Neuromag-style phantoms,
      # Locs are always in XZ or YZ, and so are the oris. The oris are
      # also in the same plane and tangential, so it's easy to determine
      # the orientation.
      # For Oyama, vectors are orthogonal to the position vector and oriented with one
      # pointed toward the north pole (except for the topmost points, which are just xy).
      ori = list()
      for pi, this_pos in enumerate(pos):
          this_ori = np.zeros(3)
          idx = np.where(this_pos == 0)[0]
          # assert len(idx) == 1
          if len(idx) == 0:  # oyama
              idx = [np.argmin(this_pos)]
          idx = np.setdiff1d(np.arange(3), idx[0])
          this_ori[idx] = (
              this_pos[idx][::-1] / np.linalg.norm(this_pos[idx])
          ) * [1, -1]
          if kind == "oyama":
              # Ensure it's orthogonal to the position vector
              pos_unit = this_pos / np.linalg.norm(this_pos)
              this_ori -= pos_unit * np.dot(this_ori, pos_unit)
              this_ori /= np.linalg.norm(this_ori)
              # This was empirically determined by looking at the dipole fits
              if (
                  np.abs(this_ori[2]) >= 1e-6
              ):  # if it's not in the XY plane
                  this_ori *= -1 * np.sign(
                      this_ori[2]
                  )  # point downward
              elif (
                  np.abs(this_ori[0]) < 1e-6
              ):  # in the XY plane (at the north pole)
                  this_ori *= -1 * np.sign(
                      this_ori[1]
                  )  # point backward
              # Odd ones create a RH coordinate system with their ori
              if pi % 2:
                  this_ori = np.cross(pos_unit, this_ori)
          else:
              this_ori *= signs[pi]
          # Now we have this quality, which we could uncomment to
          # double-check:
          # np.testing.assert_allclose(np.dot(this_ori, this_pos) /
          #                            np.linalg.norm(this_pos), 0,
          #                            atol=1e-15)
          ori.append(this_ori)
      ori = np.array(ori)
      return pos, ori
  
imports: import functools
  import re
  from copy import deepcopy
  from functools import partial
  import numpy
  from scipy.linalg import eigh
  from scipy.optimize import fmin_cobyla
  from ._fiff.constants import FIFF
  from ._fiff.pick import pick_types
  from ._fiff.proj import _needs_eeg_average_ref_proj, make_projector
  from ._freesurfer import _get_aseg, head_to_mni, head_to_mri, read_freesurfer_lut
  from .bem import _bem_find_surface, _bem_surf_name, _fit_sphere
  from .cov import _ensure_cov, compute_whitener
  from .evoked import _aspect_rev, _read_evoked, _write_evokeds
  from .fixes import _safe_svd, pinvh
  from .forward._compute_forward import _compute_forwards_meeg, _prep_field_computation
  from .forward._make_forward import _get_trans, _prep_eeg_channels, _prep_meg_channels, _setup_bem
  from .parallel import parallel_func
  from .source_space._source_space import SourceSpaces, _make_volume_source_space
  from .surface import _compute_nearest, _points_outside_surface, transform_surface_to
  from .transforms import _coord_frame_name, _print_coord_trans, apply_trans
  from .utils import ExtendedTimeMixin, TimeMixin, _check_fname, _check_option, _get_blas_funcs, _pl, _repeated_svd, _svd_lwork, _time_mask, _validate_type, _verbose_safe_false, check_fname, copy_function_doc_to_method_doc, fill_doc, logger, verbose, warn
  from .viz import plot_dipole_amplitudes, plot_dipole_locations
  from .viz.evoked import _plot_evoked
label_desc: Use image node_id 20 for calling a global function with example usage: get_phantom_dipoles(kind) and returns: pos,  ori