code: def test_parallel_multi_output():
      from SALib.test_functions import lake_problem
  
      # Create the SALib Problem specification
      sp = ProblemSpec(
          {
              "names": [
                  "a",
                  "q",
                  "b",
                  "mean",
                  "stdev",
                  "delta",
                  "alpha",
              ],
              "bounds": [
                  [0.0, 0.1],
                  [2.0, 4.5],
                  [0.1, 0.45],
                  [0.01, 0.05],
                  [0.001, 0.005],
                  [0.93, 0.99],
                  [0.2, 0.5],
              ],
              "outputs": ["max_P", "Utility", "Inertia", "Reliability"],
          }
      )
  
      # Single core example
      (
          sp.sample_saltelli(2**8)
          .evaluate(lake_problem.evaluate)
          .analyze_sobol(
              calc_second_order=True, conf_level=0.95, seed=101
          )
      )
  
      # Parallel example
      psp = copy.deepcopy(sp)
      (
          psp.sample_saltelli(2**8)
          .evaluate_parallel(lake_problem.evaluate, nprocs=2)
          .analyze_sobol(
              calc_second_order=True,
              conf_level=0.95,
              nprocs=2,
              seed=101,
          )
      )
  
      x_df = pd.DataFrame(sp.results)
      y_df = pd.DataFrame(psp.results)
      for col in pd.DataFrame(sp.results):
          z = [
              np.testing.assert_allclose(x, y)
              for x, y in zip(x_df.loc[:, col], y_df.loc[:, col])
          ]
  
          assert not any(z), "Model results are not equal!"
  
      x_df = pd.DataFrame(sp.analysis)
      y_df = pd.DataFrame(psp.analysis)
      for col in pd.DataFrame(sp.analysis):
          z = [
              np.testing.assert_allclose(x, y)
              for x, y in zip(x_df.loc[:, col], y_df.loc[:, col])
          ]
  
          assert not any(z), "Analysis results are not equal!"
  
file_path: SALib/tests/test_problem_spec.py
imports: import pytest
  import copy
  import numpy
  import pandas
  from SALib import ProblemSpec
  from SALib.test_functions import Ishigami
label_desc: Use image node_id 5 for calling a global function with example usage: test_parallel_multi_output() without return types