Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed bytemask() in favour of mask_as_bool() #1410

Merged
merged 6 commits into from
Apr 14, 2022
Merged

Conversation

ioanaif
Copy link
Collaborator

@ioanaif ioanaif commented Apr 12, 2022

No description provided.

@codecov
Copy link

codecov bot commented Apr 12, 2022

Codecov Report

Merging #1410 (37b0225) into main (edfce38) will decrease coverage by 0.02%.
The diff coverage is 45.59%.

Impacted Files Coverage Δ
src/awkward/_v2/_connect/cuda/__init__.py 0.00% <0.00%> (ø)
src/awkward/_v2/_connect/jax/__init__.py 0.00% <0.00%> (ø)
src/awkward/_v2/contents/indexedarray.py 62.32% <0.00%> (+0.43%) ⬆️
src/awkward/_v2/operations/convert/ak_from_cupy.py 50.00% <0.00%> (+23.33%) ⬆️
src/awkward/_v2/operations/convert/ak_from_jax.py 50.00% <0.00%> (-25.00%) ⬇️
src/awkward/_v2/operations/convert/ak_to_cupy.py 33.33% <0.00%> (+23.95%) ⬆️
src/awkward/_v2/operations/convert/ak_to_jax.py 33.33% <0.00%> (-41.67%) ⬇️
src/awkward/_v2/operations/describe/ak_backend.py 10.00% <0.00%> (-2.50%) ⬇️
src/awkward/_v2/_util.py 75.26% <37.06%> (-8.07%) ⬇️
src/awkward/_v2/contents/numpyarray.py 90.42% <50.00%> (-0.15%) ⬇️
... and 21 more

Copy link
Member

@jpivarski jpivarski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! I did a grep and found one more case, and I think I know why that one was there. (See below.)

This is ready to merge!

mask0 = module.asarray(array.bytemask()).view(np.bool_)
mask0 = array.mask_as_bool(valid_when=False)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This last case illustrates why we want to avoid having both bytemask and mask_as_bool. You didn't see it, @ioanaif, because it was added by @swishdiff, and @swishdiff didn't know that bytemask was being removed.

@jpivarski jpivarski enabled auto-merge (squash) April 14, 2022 21:23
@jpivarski jpivarski merged commit 5bfce86 into main Apr 14, 2022
@jpivarski jpivarski deleted the ioanaif/remove_bytemask branch April 14, 2022 21:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants