Skip to content

Commit 7bb76f9

Browse files
committed
Switch to area averaging when binning hips
1 parent a56258d commit 7bb76f9

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

python/lsst/pipe/tasks/fits2hips/_high_order_hips.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ def run(self, input_images: Iterable[tuple[NDArray, SkyWcs, Box2I]], healpix_id)
198198
self.log.info("Generating tiles for hxp level %d", hips_level)
199199
if zoom:
200200
size = 4096 // zoom
201-
binned_array = cv2.resize(output_array_hpx, (size, size), interpolation=cv2.INTER_LANCZOS4)
201+
binned_array = cv2.resize(output_array_hpx, (size, size), interpolation=cv2.INTER_AREA)
202202
else:
203203
binned_array = output_array_hpx
204204
# always create blocks of 512x512 as that is native shift order 9 size

python/lsst/pipe/tasks/fits2hips/_low_order_hips.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ def run(self, hpx_container: Iterable[tuple[DeferredDatasetHandle, int]]) -> Str
176176
size_counter += 1
177177

178178
# resample the image to a smaller grid and store it for the next order
179-
zoomed = cv2.resize(hpx_next_array, (256, 256), interpolation=cv2.INTER_LANCZOS4)
179+
zoomed = cv2.resize(hpx_next_array, (256, 256), interpolation=cv2.INTER_AREA)
180180

181181
hpx_next_container.append((zoomed, hpx_next_id))
182182
hpx_container = hpx_next_container

0 commit comments

Comments
 (0)