Closed schlunma closed 1 week ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 94.74%. Comparing base (
343368e
) to head (325db6d
). Report is 2 commits behind head on main.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
The question here is how to treat a mix of input arrays. The common choice seems to be that the output is lazy if any of the input arrays are lazy, e.g.
np.ones(2) * da.ones(2)
results in a Dask array. This kind of makes sense because it provides the lowest memory footprint and still offers the user full control because they can make all input arrays realized if they want realized output. Would that work for you?
Yes, that makes total sense, and also has the benefit of easier code. I chose to make it only depend on the actual data, not on the ancillary variables. I will change that now ๐
Description
This PR
chunks
foriris.util.broadcast_to_shape
whenever possible in our code base to improve lazy computations.mask_landsea
(see https://github.com/ESMValGroup/ESMValCore/issues/2514 for details).mask_landsea()
,mask_landseaice()
andcalculate_volume()
return lazy data for lazy input, but also realized data if all input is realized.Closes #2514
Before you get started
Checklist
It is the responsibility of the author to make sure the pull request is ready to review. The icons indicate whether the item will be subject to the ๐ Technical or ๐งช Scientific review.
To help with the number pull requests: