allow changing thread number K