Added support for multithreaded dataset processing