Skip to content

Commit

Permalink
Hiblert works for data resolution swap
Browse files Browse the repository at this point in the history
  • Loading branch information
Jammy2211 committed Apr 30, 2024
1 parent 767b86d commit 3fb1a57
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion autoarray/inversion/pixelization/image_mesh/hilbert.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,12 @@ def image_and_grid_from(image, mask, mask_radius, pixel_scales, hilbert_length):
image associated to that grid.
"""

shape_nnn = np.shape(mask)[0]
# For multi wavelength fits the input image may be a different resolution than the mask.

try:
shape_nnn = np.shape(image.native)[0]
except AttributeError:
shape_nnn = np.shape(mask)[0]

grid = Grid2D.uniform(
shape_native=(shape_nnn, shape_nnn),
Expand Down

0 comments on commit 3fb1a57

Please sign in to comment.