code: def test_MultiShellDeconvModel():
      gtab = get_3shell_gtab()
  
      mevals = np.array([wm_response[0, :3], wm_response[0, :3]])
      angles = [(0, 0), (60, 0)]
  
      S_wm, sticks = multi_tensor(
          gtab,
          mevals,
          wm_response[0, 3],
          angles=angles,
          fractions=[30.0, 70.0],
          snr=None,
      )
      S_gm = gm_response[0, 3] * np.exp(-gtab.bvals * gm_response[0, 0])
      S_csf = csf_response[0, 3] * np.exp(
          -gtab.bvals * csf_response[0, 0]
      )
  
      sh_order = 8
      with warnings.catch_warnings():
          warnings.filterwarnings(
              "ignore",
              message=shm.descoteaux07_legacy_msg,
              category=PendingDeprecationWarning,
          )
          response = multi_shell_fiber_response(
              sh_order,
              [0, 1000, 2000, 3500],
              wm_response,
              gm_response,
              csf_response,
          )
          model = MultiShellDeconvModel(gtab, response)
      vf = [0.325, 0.2, 0.475]
      signal = sum(i * j for i, j in zip(vf, [S_csf, S_gm, S_wm]))
      fit = model.fit(signal)
  
      # Testing both ways to predict
      S_pred_fit = fit.predict()
      with warnings.catch_warnings():
          warnings.filterwarnings(
              "ignore",
              message=shm.descoteaux07_legacy_msg,
              category=PendingDeprecationWarning,
          )
          S_pred_model = model.predict(fit.all_shm_coeff)
  
      npt.assert_array_almost_equal(S_pred_fit, S_pred_model, 0)
      npt.assert_array_almost_equal(S_pred_fit, signal, 0)
  
imports: import warnings
  from dipy.reconst.mcsd import mask_for_response_msmt, response_from_mask_msmt, auto_response_msmt
  from dipy.reconst.mcsd import MultiShellDeconvModel, multi_shell_fiber_response
  import numpy
  import numpy.testing
  import pytest
  from dipy.sims.voxel import single_tensor, multi_tensor, add_noise
  from dipy.reconst import shm
  from dipy.data import default_sphere, get_3shell_gtab
  from dipy.core.gradients import GradientTable
  from dipy.testing.decorators import set_random_number_generator
  from dipy.utils.optpkg import optional_package
label_desc: Use image node_id 5 for calling a global function with example usage: test_MultiShellDeconvModel() without return types