Could we pass n_jobs to lower level?


#1

I tried to use the n_jobs on predict API to make it running parallel, but it seems not working, so I checked the realization of predict, I found than “CPUPredictor::PredictBatch” do not provide “nthread/n_jobs” argument, it fetched that from omp_get_max_threads which controlled by OMP_NUM_THREADS. In my opinion, it is not a consistent API. I think we could remove n_jobs & nthread from “predict” or provide “nthread” in “CPUPredictor::PredictBatch” as well.