Skip to content

Commit

Permalink
test: clean up tests for draw
Browse files Browse the repository at this point in the history
  • Loading branch information
beckermr committed Aug 23, 2024
1 parent 682f592 commit 63855f9
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions tests/test_draw.py
Original file line number Diff line number Diff line change
Expand Up @@ -1259,10 +1259,11 @@ def test_fft():
[4,6,8,4],
[2,4,6,6] ],
xmin=-2, ymin=-2, dtype=dt, scale=0.1)
if is_jax_galsim() and dt not in [np.complex128, complex]:
kim = xim.calculate_fft()
xim2 = kim.calculate_inverse_fft()
np.testing.assert_array_almost_equal(xim.array, xim2.array)
if is_jax_galsim():
if dt not in [np.complex128, complex]:
kim = xim.calculate_fft()
xim2 = kim.calculate_inverse_fft()
np.testing.assert_array_almost_equal(xim.array, xim2.array)
else:
kim = xim.calculate_fft()
xim2 = kim.calculate_inverse_fft()
Expand Down Expand Up @@ -1298,10 +1299,11 @@ def test_fft():
xim2 = galsim.Image([ [2,4,6],
[4,6,8] ],
xmin=-2, ymin=-1, dtype=dt, scale=0.1)
if is_jax_galsim() and dt not in [np.complex128, complex]:
kim = xim.calculate_fft()
kim2 = xim2.calculate_fft()
np.testing.assert_array_almost_equal(kim.array, kim2.array)
if is_jax_galsim():
if dt not in [np.complex128, complex]:
kim = xim.calculate_fft()
kim2 = xim2.calculate_fft()
np.testing.assert_array_almost_equal(kim.array, kim2.array)
else:
kim = xim.calculate_fft()
kim2 = xim2.calculate_fft()
Expand Down

0 comments on commit 63855f9

Please sign in to comment.