docstr: Tests that a distance matrix is computed correctly for the
  local distance optimization.
  The only change is that the local method needs the upper triangle of
  the distance matrix instead of the lower one.
  
  This is for an input of six trajectories and two parameters
docstr_tok: ["Tests","that","a","distance","matrix","is","computed","correctly","for","the","local","distance","optimization",".","The","only","change","is","that","the","local","method","needs","the","upper","triangle","of","the","distance","matrix","instead","of","the","lower","one",".","This","is","for","an","input","of","six","trajectories","and","two","parameters"]
code: def test_compute_distance_matrix_local(self, strategy, setup_input):
      """
      Tests that a distance matrix is computed correctly for the
      local distance optimization.
      The only change is that the local method needs the upper triangle of
      the distance matrix instead of the lower one.
  
      This is for an input of six trajectories and two parameters
      """
      sample_inputs = setup_input
      output = strategy.compute_distance_matrix(
          sample_inputs, 6, 2, local_optimization=True
      )
      expected = np.zeros((6, 6), dtype=np.float32)
      expected[0, :] = [0, 5.50, 6.18, 6.89, 6.18, 7.52]
      expected[1, :] = [5.50, 0, 5.31, 6.18, 5.31, 5.99]
      expected[2, :] = [6.18, 5.31, 0, 6.57, 5.41, 5.52]
      expected[3, :] = [6.89, 6.18, 6.57, 0, 5.50, 7.31]
      expected[4, :] = [6.18, 5.31, 5.41, 5.5, 0, 5.77]
      expected[5, :] = [7.52, 5.99, 5.52, 7.31, 5.77, 0]
      assert_allclose(output, expected, rtol=1e-2)
  
imports: from SALib.sample.morris import SampleMorris, LocalOptimisation, BruteForce
  from SALib.sample.morris.morris import _sample_morris
  from SALib.util import read_param_file
  import numpy
  from numpy.testing import assert_equal, assert_allclose
  import numpy.random
  import pytest
  from pytest import fixture, raises
label_desc: Use image node_id 9 for calling the TestSharedMethods obj's underlying member method code with example usage: obj.test_compute_distance_matrix_local(strategy, setup_input) without return types