Fix mapchunks and add tests for it#695
Open
alecarraro wants to merge 2 commits intoJuliaParallel:masterfrom
Open
Fix mapchunks and add tests for it#695alecarraro wants to merge 2 commits intoJuliaParallel:masterfrom
mapchunks and add tests for it#695alecarraro wants to merge 2 commits intoJuliaParallel:masterfrom
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi, this PR proposes a fix for (#476). Specifically I implemented the following changes:
mapchunksnow uses the correctDArrayconstructorDagger.spawninstead offetch/collect, somapchunksintegrates with Dagger’s scheduler. I also setOptions(meta=false)explicitely to highlight thatfgets the materialized chunk data but I guess it might not be necessary._mapchunks_eltypehelper: it looks atchunktypewhen available, promotes across chunks, and falls back toAnyif type inference is not possible. I think an other option could be to usepromote_op(f, chunktype(chunk)), but then it should be documented that it fails if the chunk has heterogeneous types. What do you think?mapchunkstakes 50% longer than the testset formapon my computer. Lmk if you'd prefer it to keep it lighterAlso, the function
mapchunksis undocumented at the moment. I would be happy to fix that as well, but it makes more sense to do it after a design is finalized. Since this issue has been around for a while, I guess there might be some prior context I’m missing (i.e planned API changes). Happy to adjust if that's the case!