xgboost

model.h
Go to the documentation of this file.
1
6 #ifndef XGBOOST_MODEL_H_
7 #define XGBOOST_MODEL_H_
8
9 namespace dmlc {
10 class Stream;
11 } // namespace dmlc
12
13 namespace xgboost {
14
15 class Json;
16
17 struct Model {
18 virtual ~Model() = default;
23 virtual void LoadModel(Json const& in) = 0;
28 virtual void SaveModel(Json* out) const = 0;
29 };
30
31 struct Configurable {
32 virtual ~Configurable() = default;
37 virtual void LoadConfig(Json const& in) = 0;
42 virtual void SaveConfig(Json* out) const = 0;
43 };
44 } // namespace xgboost
45
46 #endif // XGBOOST_MODEL_H_
dmlc
Definition: data.h:592
xgboost::Model::SaveModel
virtual void SaveModel(Json *out) const =0
saves the model config to a json object
xgboost::Model
Definition: model.h:17
xgboost::Model::~Model
virtual ~Model()=default
xgboost::Model::LoadModel
virtual void LoadModel(Json const &in)=0
load the model from a json object
xgboost::Configurable::LoadConfig
virtual void LoadConfig(Json const &in)=0
Load configuration from JSON object.
xgboost::Configurable
Definition: model.h:31
xgboost::Configurable::~Configurable
virtual ~Configurable()=default
xgboost::Configurable::SaveConfig
virtual void SaveConfig(Json *out) const =0
Save configuration to JSON object.
xgboost::Json
Data structure representing JSON format.
Definition: json.h:355
xgboost
namespace of xgboost
Definition: base.h:110