autoppl
v0.8
A C++ template library for probabilistic programming
|
#include <unary.hpp>
Public Types | |
using | value_t = typename util::var_expr_traits< expr_t >::value_t |
using | shape_t = typename util::shape_traits< expr_t >::shape_t |
Public Member Functions | |
UnaryNode (const expr_t &expr) | |
template<class Func > | |
void | traverse (Func &&) const |
auto | get () const |
auto | eval () |
constexpr size_t | size () const |
constexpr size_t | rows () const |
constexpr size_t | cols () const |
template<class PtrPackType > | |
auto | ad (const PtrPackType &pack) const |
template<class PtrPackType > | |
void | bind (const PtrPackType &pack) |
void | activate_refcnt () const |
Public Member Functions inherited from ppl::util::BaseCRTP< UnaryNode< UnaryOp, VarExprType > > | |
UnaryNode< UnaryOp, VarExprType > & | self () |
const UnaryNode< UnaryOp, VarExprType > & | self () const |
Static Public Attributes | |
static constexpr bool | has_param = expr_t::has_param |
UnaryNode is a generic object representing some unary operation on a variable expression. For example, log, exp, sin, cos, tan are common unary operations.
UnaryOp | unary operation policy containing a static member function "fmap(T x)" that evaluates the corresponding unary operation on the underlying expression. |
VarExprType | variable expression type |
using ppl::expr::var::UnaryNode< UnaryOp, VarExprType >::shape_t = typename util::shape_traits<expr_t>::shape_t |
using ppl::expr::var::UnaryNode< UnaryOp, VarExprType >::value_t = typename util::var_expr_traits<expr_t>::value_t |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlineconstexpr |
|
inline |
|
inline |
|
inlineconstexpr |
|
inlineconstexpr |
|
inline |
|
staticconstexpr |