code: def test_make_sphere_model():
      """Test making a sphere model."""
      info = read_info(fname_raw)
      pytest.raises(ValueError, make_sphere_model, "foo", "auto", info)
      pytest.raises(ValueError, make_sphere_model, "auto", "auto", None)
      pytest.raises(
          ValueError,
          make_sphere_model,
          "auto",
          "auto",
          info,
          relative_radii=(),
          sigmas=(),
      )
      with pytest.raises(
          ValueError, match="relative_radii.*must match.*sigmas"
      ):
          make_sphere_model("auto", "auto", info, relative_radii=(1,))
      # here we just make sure it works -- the functionality is actually
      # tested more extensively e.g. in the forward and dipole code
      with catch_logging() as log:
          bem = make_sphere_model("auto", "auto", info, verbose=True)
      log = log.getvalue()
      assert " RV = " in log
      for line in log.split("\n"):
          if " RV = " in line:
              val = float(line.split()[-2])
              assert val < 0.01  # actually decent fitting
              break
      assert "3 layers" in repr(bem)
      assert "Sphere " in repr(bem)
      assert " mm" in repr(bem)
      bem = make_sphere_model("auto", None, info)
      assert "no layers" in repr(bem)
      assert "Sphere " in repr(bem)
      with pytest.raises(
          ValueError, match="at least 2 sigmas.*head_radius"
      ):
          make_sphere_model(sigmas=(0.33,), relative_radii=(1.0,))
  
imports: import re
  from copy import deepcopy
  from os import makedirs
  from pathlib import Path
  from shutil import copy
  import numpy
  import pytest
  from numpy.testing import assert_allclose, assert_equal
  import mne
  from mne import Info, Transform, make_bem_model, make_bem_solution, make_sphere_model, read_bem_solution, read_bem_surfaces, write_bem_solution, write_bem_surfaces, write_head_bem, write_surface
  from mne._fiff.constants import FIFF
  from mne.bem import _assert_complete_surface, _assert_inside, _bem_find_surface, _check_surface_size, _get_ico_map, _ico_downsample, _order_surfaces, distance_to_bem, fit_sphere_to_headshape, make_scalp_surfaces
  from mne.datasets import testing
  from mne.io import read_info
  from mne.surface import _get_ico_surface, read_surface
  from mne.transforms import translation
  from mne.utils import catch_logging, check_version
label_desc: Use image node_id 4 for calling a global function with example usage: test_make_sphere_model() without return types