[WIP] Extract prediction into separate interface (#2531)

* [WIP] Extract prediction into separate interface

* Add copyright, fix linter errors

* Add predictor to amalgamation

* Fix documentation

* Move prediction cache into predictor, add GBTreeModel

* Updated predictor doc comments
This commit is contained in:
Rory Mitchell
2017-07-29 12:01:03 +12:00
committed by Tianqi Chen
parent 00eda28b3c
commit 0e06d1805d
11 changed files with 835 additions and 419 deletions

View File

@@ -189,7 +189,7 @@ inline void Learner::Predict(const SparseBatch::Inst& inst,
bool output_margin,
std::vector<bst_float>* out_preds,
unsigned ntree_limit) const {
gbm_->Predict(inst, out_preds, ntree_limit);
gbm_->PredictInstance(inst, out_preds, ntree_limit);
if (!output_margin) {
obj_->PredTransform(out_preds);
}