Medial Code Documentation
Loading...
Searching...
No Matches
Public Member Functions | Data Fields
xgboost::gbm::GBTreeModel Struct Reference
Inheritance diagram for xgboost::gbm::GBTreeModel:
xgboost::Model

Public Member Functions

 GBTreeModel (LearnerModelParam const *learner_model, Context const *ctx)
 
void Configure (const Args &cfg)
 
void InitTreesToUpdate ()
 
void Load (dmlc::Stream *fi)
 
void Save (dmlc::Stream *fo) const
 
void SaveModel (Json *p_out) const override
 saves the model config to a JSON object
 
void LoadModel (Json const &p_out) override
 load the model from a JSON object
 
std::vector< std::string > DumpModel (const FeatureMap &fmap, bool with_stats, int32_t n_threads, std::string format) const
 
bst_tree_t CommitModel (TreesOneIter &&new_trees)
 Add trees to the model.
 
void CommitModelGroup (std::vector< std::unique_ptr< RegTree > > &&new_trees, bst_target_t group_idx)
 
std::int32_t BoostedRounds () const
 

Data Fields

LearnerModelParam const * learner_model_param
 
GBTreeModelParam param
 
std::vector< std::unique_ptr< RegTree > > trees
 vector of trees stored in the model
 
std::vector< std::unique_ptr< RegTree > > trees_to_update
 for the update process, a place to keep the initial trees
 
std::vector< int > tree_info
 Group index for trees.
 
std::vector< bst_tree_titeration_indptr {0}
 Number of trees accumulated for each iteration.
 

Member Function Documentation

◆ CommitModel()

bst_tree_t xgboost::gbm::GBTreeModel::CommitModel ( TreesOneIter &&  new_trees)

Add trees to the model.

Returns
The number of new trees.

◆ LoadModel()

void xgboost::gbm::GBTreeModel::LoadModel ( Json const &  in)
overridevirtual

load the model from a JSON object

Parameters
inJSON object where to load the model from

Implements xgboost::Model.

◆ SaveModel()

void xgboost::gbm::GBTreeModel::SaveModel ( Json out) const
overridevirtual

saves the model config to a JSON object

Parameters
outJSON container where to save the model to

Implements xgboost::Model.


The documentation for this struct was generated from the following files: