[GPU-Plugin] Add GPU accelerated prediction (#2593)

* [GPU-Plugin] Add GPU accelerated prediction

* Improve allocation message

* Update documentation

* Resolve linker error for predictor

* Add unit tests
This commit is contained in:
Rory Mitchell
2017-08-16 12:31:59 +12:00
committed by GitHub
parent 71e5e622b1
commit ef23e424f1
25 changed files with 876 additions and 203 deletions

View File

@@ -165,9 +165,19 @@ class LearnerImpl : public Learner {
<< "grow_fast_histmaker.";
cfg_["updater"] = "grow_fast_histmaker";
} else if (tparam.tree_method == 4) {
cfg_["updater"] = "grow_gpu,prune";
if (cfg_.count("updater") == 0) {
cfg_["updater"] = "grow_gpu,prune";
}
if (cfg_.count("predictor") == 0) {
cfg_["predictor"] = "gpu_predictor";
}
} else if (tparam.tree_method == 5) {
cfg_["updater"] = "grow_gpu_hist";
if (cfg_.count("updater") == 0) {
cfg_["updater"] = "grow_gpu_hist";
}
if (cfg_.count("predictor") == 0) {
cfg_["predictor"] = "gpu_predictor";
}
}
}