Treelite
Public Member Functions | Public Attributes | List of all members
ModelImpl< ThresholdType, LeafOutputType > Class Template Reference
Inheritance diagram for ModelImpl< ThresholdType, LeafOutputType >:
Inheritance graph
[legend]
Collaboration diagram for ModelImpl< ThresholdType, LeafOutputType >:
Collaboration graph
[legend]

Public Member Functions

 ModelImpl ()=default
 disable copy; use default move
 
 ModelImpl (const ModelImpl &)=delete
 
ModelImploperator= (const ModelImpl &)=delete
 
 ModelImpl (ModelImpl &&) noexcept=default
 
ModelImploperator= (ModelImpl &&) noexcept=default
 
void SerializeToJSON (std::ostream &fo) const override
 
std::size_t GetNumTree () const override
 
void SetTreeLimit (std::size_t limit) override
 
void GetPyBuffer (std::vector< PyBufferFrame > *dest) override
 
void SerializeToFileImpl (FILE *dest_fp) override
 
void InitFromPyBuffer (std::vector< PyBufferFrame >::iterator begin, std::vector< PyBufferFrame >::iterator end) override
 
void DeserializeFromFileImpl (FILE *src_fp) override
 
template<typename HeaderFieldHandlerFunc , typename TreeHandlerFunc >
void DeserializeTemplate (std::size_t num_tree, HeaderFieldHandlerFunc header_field_handler, TreeHandlerFunc tree_handler)
 
- Public Member Functions inherited from Model
 Model ()
 disable copy; use default move
 
 Model (const Model &)=delete
 
Modeloperator= (const Model &)=delete
 
 Model (Model &&)=default
 
Modeloperator= (Model &&)=default
 
TypeInfo GetThresholdType () const
 
TypeInfo GetLeafOutputType () const
 
template<typename Func >
auto Dispatch (Func func)
 
template<typename Func >
auto Dispatch (Func func) const
 
std::vector< PyBufferFrameGetPyBuffer ()
 
void SerializeToFile (FILE *dest_fp)
 

Public Attributes

std::vector< Tree< ThresholdType, LeafOutputType > > trees
 member trees
 
- Public Attributes inherited from Model
int num_feature
 number of features used for the model. It is assumed that all feature indices are between 0 and [num_feature]-1.
 
TaskType task_type
 Task type.
 
bool average_tree_output
 whether to average tree outputs
 
TaskParam task_param
 Group of parameters that are specific to the particular task type.
 
ModelParam param
 extra parameters
 

Additional Inherited Members

- Static Public Member Functions inherited from Model
template<typename ThresholdType , typename LeafOutputType >
static std::unique_ptr< ModelCreate ()
 
static std::unique_ptr< ModelCreate (TypeInfo threshold_type, TypeInfo leaf_output_type)
 
static std::unique_ptr< ModelCreateFromPyBuffer (std::vector< PyBufferFrame > frames)
 
static std::unique_ptr< ModelDeserializeFromFile (FILE *src_fp)
 

Detailed Description

template<typename ThresholdType, typename LeafOutputType>
class treelite::ModelImpl< ThresholdType, LeafOutputType >

Definition at line 696 of file tree.h.


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