Uh oh!
There was an error while loading. Please reload this page.
Pull xarray's nbytes from nbytes attribute on arrays - #6797
Conversation
maxrjones
commented
Jul 16, 2022
Please let me know if I should add a docstring as suggested in #6565 (comment). I didn't yet because most of the properties do not have docstrings. |
dcherian
commented
Jul 16, 2022
This would be great! Adding docstrings for the other properties would be a great (separate) PR! |
Uh oh!
There was an error while loading. Please reload this page.
dcherian
commented
Jul 19, 2022
Thanks @maxrjones can you push any WIP tests you might have for this? |
maxrjones
commented
Jul 19, 2022
If it's alright I will wait for #6804 to be merged first because that will greatly simplify testing the changes. After that PR, the following could be added to |
dcherian
commented
Jul 19, 2022
Ah great idea! |
TomNicholas
commented
Jul 20, 2022
Great first contribution @maxrjones ! #6804 should auto-merge in a sec so you can then fetch and merge in |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Co-authored-by: Illviljan <14371165+Illviljan@users.noreply.github.com>
dcherian
commented
Jul 22, 2022
Thanks @maxrjones I added a sparse variable test that fails on main. |
dcherian
left a comment
There was a problem hiding this comment.
Thanks @maxrjones This is a great and impactful PR! Welcome to Xarray
This implements the suggestion in #4842 (comment) to leave the nbytes calculation to the backend array.
Also removed the duplicate docs entry reported in #6565
DataArray.nbyteslisted twice in API doc block #6565