re-enable multithreading.
use cpu_count() from multiprocessing.