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

DArray: Operations always return DArrays, and add local partition support for MPI #408

Merged
merged 2 commits into from
Jul 20, 2023

Conversation

jpsamaroo
Copy link
Member

Rebase and tweaks of #406, and prep for DaggerMPI support

fda-tome and others added 2 commits July 20, 2023 16:54
To enable MPI support in the DArray (which is best implemented as each
MPI rank holding only a single local partition), this commit splits
AbstractBlock further by multi-partition or single-partition storage
schemes, where `Blocks <: AbstractMultiBlocks`, and a future `MPIBlocks
<: AbstractSingleBlocks`. Additionally, a DArray ctor is added for when
only a single subdomain and chunk/thunk is provided.

For easier post-hoc repartitioning of DArrays, we now store the original
user-provided partitioning scheme within the DArray, and also add it as
a type parameter. This also assists future MPI integration by allowing
for operations to dispatch on the partitioning scheme.

Finally, this commit also adjusts all DArray operations to return
DArrays, so that no lazy operators like MatMul or Map are returned to
the user. While it would be nice to be able to work with these
operators directly, the array ecosystem has generally settled on
propagating arrays of the same or similar types as the inputs to many
operations. The operators themselves are still present behind a single
materializing call, so it should be possible to expose them again in the
future if optimization opportunities become feasible.
@jpsamaroo
Copy link
Member Author

jpsamaroo commented Jul 20, 2023

Great work, thank you @fda-tome !

@jpsamaroo jpsamaroo deleted the jps/darray-single-part branch July 20, 2023 22:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants