perillaroc/porter-ng

use multi thread to convert grads data.

perillaroc opened this issue · 1 comments

Grads data is converted one by one currently. We should use multi-thread to convert several messages at the same time.

The order is an important thing in NWPC's GRIB 2 files. In the serial version, keeping order is very simple. However, it becomes more complicated to keep order in the multi-thread version. Different Grads messages can be converted to GRIB messages at the same time. But they must be written into GRIB file in a proper order. If time cost in file IO is far bigger than time cost in message convert, multi-thread version may not be necessary.

Both OpenMP and thread version is slower than serial version.