-
Notifications
You must be signed in to change notification settings - Fork 82
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
single-thread mode #3239
Comments
The bgzf handling is built around using a threadpool, so it always spawns at least one thread. It should be possible to use the constructor via stream for the input. If there should only be one thread, the gz_stream could be used, which should work for bgzf compressed files. So:
Haven't tried it yet, but this would be my hacky workaround. As for our code: |
This seems to me like a recurring issue and I am wondering if the mechanism to switch to gz-decompression in favor of bgzf-compression should be more straightforward to handle in the API. |
I agree. Another thing we had is that we used to write |
True. Following this, I could make out the following four possible decisions that could be made by the user: On output
On Input
|
Is it possible for seqan3-based programs to use only one CPU? I tried setting
seqan3::contrib::bgzf_thread_count
to 1, but the BAM-reading program still uses 200% CPU according to GNU time: one main thread and one for seqan3's decompression. Looking at the code, setting seqan3::contrib::bgzf_thread_count to 0 would not be supported, correct?I'm trying to make a CLI like that of samtools: using one CPU by default, with an option to specify additional CPUs. Is there a way to do that? Thanks!
@eseiler
The text was updated successfully, but these errors were encountered: