From 3e0f4420cb03ecd1c79da0e86261773f277ce7d5 Mon Sep 17 00:00:00 2001 From: James Nightingale Date: Sun, 15 Dec 2024 21:14:41 +0000 Subject: [PATCH] horrible refactor nearly done --- autoarray/inversion/pixelization/mappers/rectangular.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/autoarray/inversion/pixelization/mappers/rectangular.py b/autoarray/inversion/pixelization/mappers/rectangular.py index 6ae84064..6001792f 100644 --- a/autoarray/inversion/pixelization/mappers/rectangular.py +++ b/autoarray/inversion/pixelization/mappers/rectangular.py @@ -106,8 +106,10 @@ def pix_sub_weights(self) -> PixSubWeights: origin=self.source_plane_mesh_grid.origin, ).astype("int") + mappings = mappings.reshape((len(mappings), 1)) + return PixSubWeights( - mappings=mappings.reshape((len(mappings), 1)), + mappings=mappings, sizes=np.ones(len(mappings), dtype="int"), weights=np.ones( (len(self.source_plane_data_grid.grid_over_sampled), 1), dtype="int"