Skip to content

Commit

Permalink
Fix typo in calculation of max_pixels (#3073)
Browse files Browse the repository at this point in the history
  • Loading branch information
lukas-paulun committed Apr 18, 2024
1 parent c9e29eb commit ef62b83
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rasterio/merge.py
Original file line number Diff line number Diff line change
Expand Up @@ -333,7 +333,7 @@ def nullcontext(obj):
dst = rasterio.open(dst_path, "w", **out_profile)
exit_stack.enter_context(dst)

max_pixels = mem_limit * 1.0e6 / np.dtype(dt).itemsize * output_count
max_pixels = mem_limit * 1.0e6 / (np.dtype(dt).itemsize * output_count)

if output_width * output_height < max_pixels:
chunks = [((0, 0), windows.Window(0, 0, output_width, output_height))]
Expand Down

0 comments on commit ef62b83

Please sign in to comment.