| Modifier and Type | Interface and Description |
|---|---|
static class |
GradBooster.Factory |
| Modifier and Type | Method and Description |
|---|---|
void |
loadModel(ModelReader reader,
boolean with_pbuffer)
Loads model from stream.
|
double[] |
predict(FVec feat,
int ntree_limit)
Generates predictions for given feature vector.
|
int[] |
predictLeaf(FVec feat,
int ntree_limit)
Predicts the leaf index of each tree.
|
double |
predictSingle(FVec feat,
int ntree_limit)
Generates a prediction for given feature vector.
|
void |
setNumClass(int num_class) |
void setNumClass(int num_class)
void loadModel(ModelReader reader, boolean with_pbuffer) throws java.io.IOException
reader - input streamwith_pbuffer - whether the incoming data contains pbufferjava.io.IOException - If an I/O error occursdouble[] predict(FVec feat, int ntree_limit)
feat - feature vectorntree_limit - limit the number of trees used in predictiondouble predictSingle(FVec feat, int ntree_limit)
This method only works when the model outputs single value.
feat - feature vectorntree_limit - limit the number of trees used in predictionint[] predictLeaf(FVec feat, int ntree_limit)
feat - feature vectorntree_limit - limit the number of trees used in prediction