Using Parallel Processing in SMOKE

Is it possible to use parallel processing (OpenMP, MPI) in SMOKE to speed up the processing time of emissions source sectors such as onroad mobile. I notice that processing onroad mobile source in SMOKE takes way longer compared to other sources.

You can run separate months of onroad in separate computers / processing streams to achieve a coarse parallelism.

Yes, several programs in SMOKE have been parallelized with OpenMP, such as Movesmrg which is the slowest programs while it is processing RPD sector. We did not spend too much effort to fully parallelize the code so the speed up is somewhat limited and it can go up to 4 times faster.

@bbaek is there a code example on how to implement OpenMP in the run script to run Movesmrg? This implementation combined @eyth.alison suggestion would greatly help solve this issue for me. Currently, I am running SMOKEv4.7. Is the pre-compiled Movesmrg for this SMOKE version already compatible with OpenMP or will I have to compile it again?

If you run each month separately, you will achieve 12x parallelism even without OpenMP…

Plus there are separate streams (one for each type of activity data that can also be run in parallel)

Yes, SMOKE v4.7 has been compiled with openmp flag if I am not mistaken. it has been a while since the release. If it is, then you can simply set this flag “OMP_NUM_THREAD” in your SMOKE run script to enable the OpenMP.

setenv OMP_NUM_THREAD 8

Just want to caution you that, this OpenMP has been implemented back in 2016 and hasn’t been tested since then. So, if you run into an issue or do not see any improvement, then what @eyth.alison is suggesting is the right way to get the processing parallelization done.