usgs / groundmotion-processing

Parsing and processing ground motion data
Other
54 stars 42 forks source link

Fix parallization #1007

Closed emthompson-usgs closed 1 year ago

emthompson-usgs commented 1 year ago

There's a problem with how ProcessPoolExecutor is getting called and it is causing the calculations to not actually be run in parallel. Thanks to @baagaard-usgs for pointing this out and finding the fix: the with ProcessPoolExecutor(...) command needs to be pulled outside of the loop.