-
Notifications
You must be signed in to change notification settings - Fork 32
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
[Feature] Parallelize kwavearray functions #523
Comments
This is a great point. Should be easy to implement. Thanks for your feedback.
…-Walter
|
What would be the best approach? There are a few things which can be done to accelerate the code: refactoring with list comprehension to remove loops; joblib; JIT with numba; cupy. |
I just looked into This is the original loop:
In |
I could also reduce |
That would be great. Thanks @faberno! |
@faberno should we try to get these updates into v0.4.1 in the new year? |
That would be great. Will open my promised PR tomorrow |
Is your feature request related to a problem? Please describe.
I was wondering if its possible to parallelize
get_array_binary_mask
andcombine_sensor_data
of thekWaveArray
class.For simulations with many array elements these functions are a major bottleneck.
Describe the solution you'd like
Currently these functions contain a loop which iterates over every element. But the iterations are independent of each other, so in theory it should be possible to multiprocess them. This would probably require some refactoring to avoid copying the kwavearray and kgrid class for every thread.
The text was updated successfully, but these errors were encountered: