Skip to content

Commit

Permalink
Fixes failing Sobol Sensitivity tests
Browse files Browse the repository at this point in the history
  • Loading branch information
dimtsap committed Aug 26, 2022
1 parent bc15e7f commit ec2f910
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/unit_tests/sensitivity/test_sobol.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,9 +146,9 @@ def saltelli_ishigami_Sobol_indices(sobol_object):

np.random.seed(12345) #! set seed for reproducibility

computed_indices = SA.run(n_samples=1_000_000)
SA.run(n_samples=1_000_000)

return computed_indices["sobol_i"], computed_indices["sobol_total_i"]
return SA.first_order_indices, SA.total_order_indices


@pytest.fixture()
Expand Down Expand Up @@ -335,9 +335,9 @@ def saltelli_sobol_g_function(sobol_object_g_func):

# Compute Sobol indices using the pick and freeze algorithm
# Save only second order indices
computed_indices = SA.run(n_samples=100_000, estimate_second_order=True)
SA.run(n_samples=100_000, estimate_second_order=True)

return computed_indices["sobol_ij"]
return SA.second_order_indices


# Unit tests
Expand Down

0 comments on commit ec2f910

Please sign in to comment.