treelite
Typedefs | Enumerations | Functions | Variables
base.h File Reference

defines configuration macros of treelite More...

#include <string>
#include <unordered_map>
#include <cstdint>
Include dependency graph for base.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef double tl_float
 float type to be used internally
 

Enumerations

enum  SplitFeatureType : int8_t { kNone, kNumerical, kCategorical }
 feature split type
 
enum  Operator : int8_t {
  kEQ, kLT, kLE, kGT,
  kGE
}
 comparison operators
 

Functions

std::string OpName (Operator op)
 get string representation of comparsion operator More...
 

Variables

const std::unordered_map< std::string, Operator > optable
 conversion table from string to operator, defined in optable.cc More...
 

Detailed Description

defines configuration macros of treelite

Copyright 2017 by Contributors

Author
Philip Cho

Definition in file base.h.

Function Documentation

std::string treelite::OpName ( Operator  op)
inline

get string representation of comparsion operator

Parameters
opcomparison operator
Returns
string representation

Definition at line 38 of file base.h.

Variable Documentation

const std::unordered_map< std::string, Operator > optable
Initial value:
{
{"==", Operator::kEQ},
{"<", Operator::kLT},
{"<=", Operator::kLE},
{">", Operator::kGT},
{">=", Operator::kGE}
}

conversion table from string to operator, defined in optable.cc

Definition at line 12 of file optable.cc.