code: def _simulate_pred_intervals(model, h, level):
      np.random.seed(1)
      nsim = 5000
      y_path = np.zeros([nsim, h])
  
      for k in range(nsim):
          e = np.random.normal(
              0, np.sqrt(model["sigma2"]), model["states"].shape
          )
          states = model["states"]
          fcsts = np.zeros(h, dtype=np.float32)
          cesforecast(
              states=states + e,
              n=model["n"],
              m=model["m"],
              season=switch_ces(model["seasontype"]),
              h=h,
              f=fcsts,
              **model["par"],
          )
          y_path[k,] = fcsts
  
      lower = np.quantile(y_path, 0.5 - np.array(level) / 200, axis=0)
      upper = np.quantile(y_path, 0.5 + np.array(level) / 200, axis=0)
      pi = {
          **{f"lo-{lv}": lower[i] for i, lv in enumerate(level)},
          **{f"hi-{lv}": upper[i] for i, lv in enumerate(level)},
      }
  
      return pi
  
imports: import math
  from typing import Tuple
  import numpy
  from numba import njit
  from statsmodels.tsa.seasonal import seasonal_decompose
  from .ets import restrict_to_bounds, results
  from .utils import CACHE, NOGIL
label_desc: Use image node_id 14 for calling a global function with example usage: _simulate_pred_intervals(model, h, level) and returns: pi