-
Notifications
You must be signed in to change notification settings - Fork 15
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
BossRemote#get_cutout parallelism #52
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome how easy that was to parallelize!
I'd been putting it off for years because I figured it was going to be hard... This isn't perfect; ideally we'd parallelize writing to the For most use-cases, it's a tiny piece of the overall time profile: For very large arrays, that recombination is a nontrivial time cost, and then it's probably worth it! But I don't know what "very large" means... Multi-GB? 100 GB? At a certain point, you're swapping instead of writing to RAM, and then ain't no thang going to speed you up. So for now, I'm leaving it... |
@movestill: Questions before I merge:
My understanding is that both of these are no's, but just putting up a final check before we merge :) |
I don't think so, either.
The only thing that I can think of that uses intern and may be parallelized is the ingest client's intern plugin. For that plugin, maybe we just turn parallel off when it uses |
Cool. Yeah I agree w.r.t the ingest plugin. I'll make a complementary PR in that repo shortly! Anecdotally, I have a feeling that it'd even be fine to leave it turned on there, since the ingest client will likely spend a bunch of time in other phases of the ingest job besides the get_cutout portion, too, and this will help it saturate its downlink. |
You can now pass a
parallel=True
(will use your number of cores) orparallel=<int number of jobs>
argument toBossRemote#get_cutout
in order to spread chunk downloads over amultiprocessing.Pool#starmap
.On a few informal stress-tests, this improved download speed by 37–40%.
You can still use the old behavior with
parallel=False
.