[SYSTEMDS-3891] OOC Source Streams #2389
Draft
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.
This PR depends on #2387.
This patch introduces a new
SourceStreamwhich is produced byOOCReblockInstruction. This change aims to prevent redundant disk writes caused byCachingStreams evicting the direct output of an upstream reblock instruction. TheSourceStreamtriggers custom cache handling in theCachingStreamand maintains an index for future direct access of source tiles on disk.These changes lead to significant speedups, allowing us to perform PCA on a 1Mx1000 input matrix in ~26s compared to the previous ~40s on our local machine (although some of the observed speedups came from the now parallel read in
OOCReblockInstructionwhich was previously not possible due to OOM errors for 5GB of allowed RAM).In addition, we are now able to run the same PCA script with 1GB of memory, which completes in ~31s.
5GB:

1GB:
