|
| | Operator ()=default |
template<typename T = ArgTypes>
requires (is_std_array_v<T> || is_eigen_array_v<T>) |
| T | get_kids (const Dataset &d, TreeNode &tn, const W **weights=nullptr) const |
| | get a std::array or eigen array of kids
|
| template<int I> |
| NthType< I > | get_kid (const Dataset &d, TreeNode &tn, const W **weights) const |
| | gets one kid for a tuple of kids
|
template<typename T, size_t ... Is>
requires (is_tuple_v<T>) |
| T | get_kids_seq (const Dataset &d, TreeNode &tn, const W **weights, std::index_sequence< Is... >) const |
| | Makes and returns a tuple of child outputs.
|
template<typename T = ArgTypes>
requires (is_tuple_v<T>) |
| T | get_kids (const Dataset &d, TreeNode &tn, const W **weights=nullptr) const |
| | get a std::tuple of kids. Used when child arguments are different types.
|
template<typename T = ArgTypes>
requires ( is_std_array_v<T> || is_tuple_v<T>) |
| RetType | apply (const T &inputs) const |
| | Apply node function in a functional style.
|
template<typename T = ArgTypes>
requires ( is_eigen_array_v<T> && !is_std_array_v<T>) |
| RetType | apply (const T &inputs) const |
| | Apply the node function like a function.
|
| template<typename T = ArgTypes, typename Scalar = RetType::Scalar> |
| RetType | eval (const Dataset &d, TreeNode &tn, const W **weights=nullptr) const |
| | evaluate the operator on the data. main entry point.
|
template<typename T = ArgTypes, typename Scalar = RetType::Scalar>
requires is_in_v<NT, NodeType::OffsetSum> |
| RetType | eval (const Dataset &d, TreeNode &tn, const W **weights=nullptr) const |
template<
NodeType NT, typename S, bool Fit, typename E = void>
struct Brush::Operator< NT, S, Fit, E >
Core computation of a node's function to data.
- Template Parameters
-
| S | the signature of the node |
| NT | node type |
| Fit | true: fit, false: predict |
| E | used for node type specialization |
Definition at line 90 of file operator.h.
template<
NodeType NT, typename S, bool Fit, typename E = void>
Initial value:conditional_t<
((UnaryOp<NT> || NaryOp<NT>) && S::ArgCount > 1),
Array<typename S::FirstArg::Scalar, -1, S::ArgCount>,
typename S::ArgTypes>
set argument types to those of the signature unless:
a) the operator is unary and there are more than one arguments b) the operator is binary and associative
In the case of a) or b), arguments to the operator are stacked into an array and the operator is applied to that array
Definition at line 101 of file operator.h.