Interface of gradient boosting model.
GradBooster
01 Syntax
Microsoft.VisualBasic.MachineLearning.XGBoost.gbm.GradBooster
02 Methods
| Name | Overloads | Summary |
|---|---|---|
| loadModel | 1 | Loads model from stream. |
| predict | 1 | Generates predictions for given feature vector. |
| predictSingle | 1 | Generates a prediction for given feature vector. |
| predictLeaf | 1 | Predicts the leaf index of each tree. |
03 Properties
| Name | Overloads | Summary |
|---|---|---|
| numClass | 1 |
04 Members
loadModel(ModelReader,
Boolean)Loads model from stream.
Parameters
| Name | Type | Description |
|---|---|---|
reader | ModelReader | input stream |
with_pbuffer | Boolean | whether the incoming data contains pbuffer |
predict(FVec,
Int32)Generates predictions for given feature vector.
Parameters
| Name | Type | Description |
|---|---|---|
feat | FVec | feature vector |
ntree_limit | Int32 | limit the number of trees used in prediction |
Returns
prediction result
predictSingle(FVec,
Int32)Generates a prediction for given feature vector.
This method only works when the model outputs single value.
Parameters
| Name | Type | Description |
|---|---|---|
feat | FVec | feature vector |
ntree_limit | Int32 | limit the number of trees used in prediction |
Returns
prediction result
predictLeaf(FVec,
Int32)Predicts the leaf index of each tree. This is only valid in gbtree predictor.
Parameters
| Name | Type | Description |
|---|---|---|
feat | FVec | feature vector |
ntree_limit | Int32 | limit the number of trees used in prediction |
Returns
predicted leaf indexes
numClass