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
Nested withPool issues #55
Comments
@russel, thank you for adding the label. Are there any news on this? |
@lacan I am just emerging from a period taken up with conferences and other stuff. I should be able to get back to GPars stuff fairly soon. In the interim: I am not sure I quite understand the phrasing. "n threads to each work on k threads" doesn't make sense to me. This may be my fault, but it doesn't alter the fact that I don't have a mental model of the problem you have. |
Hi @russel I have a certain amount of RAM which allows me to store n large image stacks at the same. For each of these image stacks, I need to load individual slices. Each slice is compressed and takes some CPU power to decompress before it can be loaded to memory, creating a bottleneck during opening, not linked to disk read time, but overhead from the decompression (the files are small too) For one image, I can run k threads that each open an image and put it in the right place in memory, and that works perfectly. However, I wanted to run that in parallel for the n images as well, so it looks like this
This currently works fine, however it creates more threads than what I would expect (n x k) at any given time. Again you can see the minimal example on my first post. Thanks again for getting back to me. |
Hummm… an area of GPars I am not that familiar with. I wonder if What we should create here is a small test program using the nested |
ah I see this was resolved using 'Gpars.withExistingPool'. |
Hi all,
We have a project where we would need n threads to each work on k threads on a particular problem.
So nested withPool(n) and eachParallel calls seemed to make sense.
However it is using way too many threads, as per this example from 2014
http://markmail.org/message/ccr4zk4v2jh22g3n
https://gist.github.com/TioBorracho/caee991b0b43a5bd70b8
What would be the best way to have nested withPool calls?
All the best
The text was updated successfully, but these errors were encountered: