JamesYang007 / autoppl

C++ template library for probabilistic programming
https://jamesyang007.github.io/autoppl/
MIT License
45 stars 5 forks source link

Add support for multiple samples #12

Closed jacobaustin123 closed 4 years ago

jacobaustin123 commented 4 years ago

This is an initial draft PR for adding support for multiple samples. There is significant work to be done still, but the basic approach is to shift from any reliance on converting Variables to their value_t, and instead using get_values(int i) to access entries within the Variable.

To do:

  1. Add support for VariableView class that views but does not own external data.
  2. Improve data storage in Variable, e.g. create an allocator that uses stack allocation whenever possible.