-
Notifications
You must be signed in to change notification settings - Fork 5
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
BrokenProcessPool #46
Comments
Hi @oschwengers, I haven't used future-based concurrency that much, but I notice that you're using Cheers 😄 |
Thanks @althonos, Anyways, thanks a lot for this! I'll test this a bit and maybe re-active the parallel gene prediction in Bakta which indeed saves a few tens of seconds in |
Indeed, Cython lets you declare code that runs in no-GIL mode, but for that you need to have code that doesn't interact with the Python interpreter in any way during these sections -- this is the case in Pyrodigal because the whole computation uses C data structures (from the Prodigal code) and only wraps the results at the very end of the computation 🙂 I'll try to have a look at the process pool eventually but I don't have ideas as to what could be wrong right now ! |
Ah, I see. Thanks for the explanation. So far, everything seem to work using the ThreadPool which - of course - is faster on its own by avoiding all the back-and-forth copying of data, external process overhead, etc. |
By the way, it looks like the error with |
Thanks a lot for the confirmation and quick fix. Indeed, the |
Hi @althonos,
thanks for the recent
3.0
version and all its improvements. I'm currently working on a patch to bring this into Bakta.Primary, I wanted to implement a multi-threaded version of this as suggested in https://github.com/althonos/pyrodigal#-thread-safety. However, in
meta
mode, I always run into aconcurrent.futures.process.BrokenProcessPool
. I cannot 100% rule out that maybe there is something wrong on our site, but after playing around and running a minimal example, I wanted to let you know - just in case there might be bug lurking in Pyrodigal.So, using a small plasmid as input, the following minimal example is working as expected:
However, If i switch to a parallel setup, this is not working anymore:
Giving this stacktrace:
So this only occurs in
meta
mode; the parallel implementation works fine in parallel on larger sequences running in default non-meta mode. Any ideas why this is not working? Thanks a lot in advance!Best regards
Oliver
The text was updated successfully, but these errors were encountered: