Brush C++ API
A flexible interpretable machine learning framework
Loading...
Searching...
No Matches
nodetype.cpp
Go to the documentation of this file.
1
#include "
nodetype.h
"
2
3
namespace
Brush
{
4
5
std::map<std::string, NodeType>
NodeNameType
= {
6
//arithmetic
7
{
"Add"
,
NodeType::Add
},
8
{
"Sub"
,
NodeType::Sub
},
9
{
"Mul"
,
NodeType::Mul
},
10
{
"Div"
,
NodeType::Div
},
11
/* {"Aq", NodeType::Aq}, */
12
{
"Abs"
,
NodeType::Abs
},
13
{
"Acos"
,
NodeType::Acos
},
14
{
"Asin"
,
NodeType::Asin
},
15
{
"Atan"
,
NodeType::Atan
},
16
{
"Cos"
,
NodeType::Cos
},
17
{
"Cosh"
,
NodeType::Cosh
},
18
{
"Sin"
,
NodeType::Sin
},
19
{
"Sinh"
,
NodeType::Sinh
},
20
{
"Tan"
,
NodeType::Tan
},
21
{
"Tanh"
,
NodeType::Tanh
},
22
{
"Ceil"
,
NodeType::Ceil
},
23
{
"Floor"
,
NodeType::Floor
},
24
{
"Exp"
,
NodeType::Exp
},
25
{
"Log"
,
NodeType::Log
},
26
{
"Logabs"
,
NodeType::Logabs
},
27
{
"Log1p"
,
NodeType::Log1p
},
28
{
"Sqrt"
,
NodeType::Sqrt
},
29
{
"Sqrtabs"
,
NodeType::Sqrtabs
},
30
{
"Square"
,
NodeType::Square
},
31
{
"Pow"
,
NodeType::Pow
},
32
{
"Logistic"
,
NodeType::Logistic
},
33
34
// logic
35
{
"And"
,
NodeType::And
},
36
{
"Or"
,
NodeType::Or
},
37
{
"Not"
,
NodeType::Not
},
38
// {"Xor", NodeType::Xor},
39
40
// decision (same)
41
/* {"Equals", NodeType::Equals}, */
42
/* {"LessThan", NodeType::LessThan}, */
43
/* {"GreaterThan", NodeType::GreaterThan}, */
44
/* {"Leq", NodeType::Leq}, */
45
/* {"Geq", NodeType::Geq}, */
46
47
// reductions
48
{
"Min"
,
NodeType::Min
},
49
{
"Max"
,
NodeType::Max
},
50
{
"Mean"
,
NodeType::Mean
},
51
{
"Median"
,
NodeType::Median
},
52
{
"Count"
,
NodeType::Count
},
53
{
"Sum"
,
NodeType::Sum
},
54
{
"OffsetSum"
,
NodeType::OffsetSum
},
55
{
"Prod"
,
NodeType::Prod
},
56
{
"ArgMax"
,
NodeType::ArgMax
},
57
58
// transforms
59
{
"Softmax"
,
NodeType::Softmax
},
60
61
// timing masks
62
{
"Before"
,
NodeType::Before
},
63
{
"After"
,
NodeType::After
},
64
{
"During"
,
NodeType::During
},
65
66
//split
67
{
"SplitBest"
,
NodeType::SplitBest
},
68
{
"SplitOn"
,
NodeType::SplitOn
},
69
70
// leaves
71
{
"MeanLabel"
,
NodeType::MeanLabel
},
72
{
"Constant"
,
NodeType::Constant
},
73
{
"Terminal"
,
NodeType::Terminal
},
74
75
// custom
76
{
"CustomUnaryOp"
,
NodeType::CustomUnaryOp
},
77
{
"CustomBinaryOp"
,
NodeType::CustomBinaryOp
},
78
{
"CustomSplit"
,
NodeType::CustomSplit
}
79
};
80
81
std::map<NodeType,std::string>
NodeTypeName
=
Util::reverse_map
(
NodeNameType
);
82
}
// Brush
Brush::Util::reverse_map
static map< V, K > reverse_map(const map< K, V > &m)
Given a map from keys to values, creates a new map from values to keys.
Definition
utils.h:738
Brush
< nsga2 selection operator for getting the front
Definition
data.cpp:12
Brush::NodeType::Log1p
@ Log1p
Brush::NodeType::Sin
@ Sin
Brush::NodeType::Tan
@ Tan
Brush::NodeType::SplitOn
@ SplitOn
Brush::NodeType::Abs
@ Abs
Brush::NodeType::MeanLabel
@ MeanLabel
Brush::NodeType::Softmax
@ Softmax
Brush::NodeType::Prod
@ Prod
Brush::NodeType::Or
@ Or
Brush::NodeType::Mean
@ Mean
Brush::NodeType::Cosh
@ Cosh
Brush::NodeType::Div
@ Div
Brush::NodeType::ArgMax
@ ArgMax
Brush::NodeType::OffsetSum
@ OffsetSum
Brush::NodeType::Terminal
@ Terminal
Brush::NodeType::CustomUnaryOp
@ CustomUnaryOp
Brush::NodeType::Mul
@ Mul
Brush::NodeType::Median
@ Median
Brush::NodeType::Max
@ Max
Brush::NodeType::During
@ During
Brush::NodeType::Asin
@ Asin
Brush::NodeType::Min
@ Min
Brush::NodeType::After
@ After
Brush::NodeType::Sqrtabs
@ Sqrtabs
Brush::NodeType::Pow
@ Pow
Brush::NodeType::Before
@ Before
Brush::NodeType::Logabs
@ Logabs
Brush::NodeType::Sinh
@ Sinh
Brush::NodeType::Logistic
@ Logistic
Brush::NodeType::Sum
@ Sum
Brush::NodeType::Not
@ Not
Brush::NodeType::Sqrt
@ Sqrt
Brush::NodeType::CustomBinaryOp
@ CustomBinaryOp
Brush::NodeType::Ceil
@ Ceil
Brush::NodeType::And
@ And
Brush::NodeType::Atan
@ Atan
Brush::NodeType::Exp
@ Exp
Brush::NodeType::Constant
@ Constant
Brush::NodeType::Tanh
@ Tanh
Brush::NodeType::Log
@ Log
Brush::NodeType::Square
@ Square
Brush::NodeType::CustomSplit
@ CustomSplit
Brush::NodeType::Sub
@ Sub
Brush::NodeType::Count
@ Count
Brush::NodeType::Add
@ Add
Brush::NodeType::Acos
@ Acos
Brush::NodeType::Floor
@ Floor
Brush::NodeType::SplitBest
@ SplitBest
Brush::NodeType::Cos
@ Cos
Brush::NodeNameType
std::map< std::string, NodeType > NodeNameType
Definition
nodetype.cpp:5
Brush::NodeTypeName
std::map< NodeType, std::string > NodeTypeName
Definition
nodetype.cpp:81
nodetype.h
src
program
nodetype.cpp
Generated by
1.10.0