|
template<typename I , typename O , typename... Ts> |
using | gpp_t = std::function< O(gr_pair< Ts... > &, I)> |
| A shorthand for graph probabilistic program type. Graph probabilistic programs are callables that take a single input of type I, output a single value of type O, and contain an arbitrary positive number of distributions of type Ts... More...
|
|
template<typename... Ts> |
using | graph_node_map_t = std::unordered_map< std::string, var_graph_node_t< Ts... > > |
|
using | graph_repr_t = std::unordered_map< std::string, std::vector< std::string > > |
|
template<typename... Ts> |
using | var_graph_node_t = std::variant< graph_node< Ts >... > |
|
template<typename... Ts> |
using | var_graph_ret_t = std::variant< DSType< Ts >... > |
|
|
std::vector< std::string > | address_or_string_null (std::vector< std::optional< std::string >> maybe_strings) |
|
template<typename... Ts> |
std::string | display (gr_pair< Ts... > &gr) |
|
template<typename... Ts> |
std::string | display (graph_ir< Ts... > &g) |
| Returns a human-readable string representation of the graph. More...
|
|
template<typename D > |
std::optional< std::string > | extract_address (graph_node< D > &v) |
|
template<typename V > |
std::optional< std::string > | extract_address (V v) |
|
template<typename D > |
DSType< D > | extract_value (graph_node< D > &v) |
|
template<typename V > |
V | extract_value (V v) |
|
template<typename D , typename... Args> |
D | make_from_args (Args... args) |
|
template<typename D , typename V , typename... Ts> |
graph_observe_node_construct< D, V, Ts... > | observe_g (gr_pair< Ts... > &gr, std::string &&address, V value) |
| Prepares an observe node for construction and placement in the graph. More...
|
|
template<typename D , typename RNG , typename... Ts> |
graph_sample_node_construct< D, RNG, Ts... > | sample_g (gr_pair< Ts... > &gr, std::string &&address, RNG &rng) |
| Prepares a sample node for construction and placement in the graph. More...
|
|
template<typename T > |
std::string | stringify (std::optional< T > t) |
|
template<> |
std::string | stringify (std::string t) |
|
template<typename I , typename O , typename... Ts> |
pp_t< I, gr_output< O, Ts... >, Ts... > | to_pp (gpp_t< I, O, Ts... > &f) |
| Convert a graph probabilistic program into a (record-based) probabilistic program. More...
|
|
template<typename V , typename... Ts> |
graph_node< Value< V > > | value_g (gr_pair< Ts... > &gr, std::string &&address, V value) |
| Creates a value node and places it in the graph. More...
|
|