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

Read frames in parallel using multiple threads #65

Merged
merged 2 commits into from
Mar 24, 2022

Conversation

hackermd
Copy link
Collaborator

This PR introduces a change to the image file reader that is used by the DICOMfileClient to read individual frames from multi-frame images. So far, frames have been read sequentially. Now, we'll use a multiprocessing.pool.ThreadPool to read multiple frames in parallel. We use threads instead of processes, because the read operation is I/O bound rather than CPU bound and the GIL should thus not be a bottleneck.

@hackermd hackermd added the enhancement New feature or request label Mar 24, 2022
@hackermd hackermd requested a review from cgorman March 24, 2022 18:01
@hackermd hackermd self-assigned this Mar 24, 2022
@hackermd hackermd merged commit 19c8db8 into master Mar 24, 2022
@hackermd hackermd deleted the enhancement/parallel-frame-retrieval branch March 24, 2022 18:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant