Skip to content

Commit

Permalink
Fix unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
smokestacklightnin committed Aug 16, 2023
1 parent 259b710 commit 62f61d5
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions stardis/opacities/tests/test_voigt.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,13 +151,13 @@ def test_voigt_profile_division_by_zero(
@pytest.mark.parametrize(
"voigt_profile_sample_values_input_delta_nu, voigt_profile_sample_values_input_doppler_width, voigt_profile_sample_values_input_gamma, voigt_profile_sample_values_expected_result",
[
(0, 1, 0, 1 / sqrt(np.pi)),
(0, 2, 0, 1 / (sqrt(np.pi) * 2)),
(0, 1, 0, 1 / sqrt(np.pi) / sqrt(2)),
(0, 2, 0, 1 / (sqrt(np.pi) * 2 * sqrt(2))),
(
np.array([0, 0]),
np.array([1, 2]),
np.array([0, 0]),
np.array([1 / sqrt(np.pi), 1 / (sqrt(np.pi) * 2)]),
np.array([1 / sqrt(2) / sqrt(np.pi), 1 / (sqrt(2) * sqrt(np.pi) * 2)]),
),
],
)
Expand Down Expand Up @@ -188,7 +188,7 @@ def test_voigt_profile_sample_values_sample_values(
np.array([0, 0]),
np.array([1, 2]),
np.array([0, 0]),
np.array([1 / sqrt(np.pi), 1 / (sqrt(np.pi) * 2)]),
np.array([1 / sqrt(2) / sqrt(np.pi), 1 / (sqrt(np.pi) * 2 * sqrt(2))]),
),
],
)
Expand Down Expand Up @@ -229,7 +229,7 @@ def test_voigt_profile_cuda_unwrapped_sample_values(
np.array([0, 0]),
np.array([1, 2]),
np.array([0, 0]),
np.array([1 / sqrt(np.pi), 1 / (sqrt(np.pi) * 2)]),
np.array([1 / sqrt(2) / sqrt(np.pi), 1 / (sqrt(2) * sqrt(np.pi) * 2)]),
),
],
)
Expand Down Expand Up @@ -261,7 +261,7 @@ def test_voigt_profile_cuda_wrapped_sample_numpy_values(
np.array([0, 0]),
np.array([1, 2]),
np.array([0, 0]),
np.array([1 / sqrt(np.pi), 1 / (sqrt(np.pi) * 2)]),
np.array([1 / sqrt(np.pi) / sqrt(2), 1 / (sqrt(np.pi) * 2 * sqrt(2))]),
),
],
)
Expand Down

0 comments on commit 62f61d5

Please sign in to comment.