gen-rs

所属分类:内容生成
开发工具:Rust
文件大小:0KB
下载次数:0
上传日期:2023-08-23 13:03:03
上 传 者sh-1993
说明:  Rust中的概率编程,建模和推理由生成函数接口(GFI)分隔。,
(Probabilistic programming in Rust, with modeling and inference separated by a Generative Function Interface (GFI).,)

文件列表:
Cargo.toml (55, 2023-12-18)
LICENSE (1102, 2023-12-18)
gen-rs/ (0, 2023-12-18)
gen-rs/Cargo.toml (686, 2023-12-18)
gen-rs/src/ (0, 2023-12-18)
gen-rs/src/address.rs (2516, 2023-12-18)
gen-rs/src/gfi.rs (3569, 2023-12-18)
gen-rs/src/inference/ (0, 2023-12-18)
gen-rs/src/inference/importance.rs (1198, 2023-12-18)
gen-rs/src/inference/mh.rs (2409, 2023-12-18)
gen-rs/src/inference/mod.rs (224, 2023-12-18)
gen-rs/src/inference/particle_filter.rs (4723, 2023-12-18)
gen-rs/src/lib.rs (1678, 2023-12-18)
gen-rs/src/mathutils.rs (402, 2023-12-18)
gen-rs/src/modeling/ (0, 2023-12-18)
gen-rs/src/modeling/dists/ (0, 2023-12-18)
gen-rs/src/modeling/dists/bernoulli.rs (445, 2023-12-18)
gen-rs/src/modeling/dists/categorical.rs (905, 2023-12-18)
gen-rs/src/modeling/dists/distribution.rs (1517, 2023-12-18)
gen-rs/src/modeling/dists/mod.rs (248, 2023-12-18)
gen-rs/src/modeling/dists/mvnormal.rs (1421, 2023-12-18)
gen-rs/src/modeling/dists/normal.rs (829, 2023-12-18)
gen-rs/src/modeling/dists/uniform.rs (1609, 2023-12-18)
gen-rs/src/modeling/mod.rs (40, 2023-12-18)
gen-rs/src/modeling/triefn.rs (16584, 2023-12-18)
gen-rs/src/trie.rs (8316, 2023-12-18)
gen-rs/tests/ (0, 2023-12-18)
gen-rs/tests/dists.rs (6300, 2023-12-18)
gen-rs/tests/hmm/ (0, 2023-12-18)
gen-rs/tests/hmm/forward.rs (842, 2023-12-18)
gen-rs/tests/hmm/mod.rs (120, 2023-12-18)
gen-rs/tests/hmm/model.rs (2770, 2023-12-18)
gen-rs/tests/hmm/trace.rs (814, 2023-12-18)
gen-rs/tests/importance.rs (4947, 2023-12-18)
gen-rs/tests/mh.rs (3852, 2023-12-18)
... ...

# gen-rs [github](https://github.com/agarret7/gen-rs) [crates.io](https://crates.io/crates/gen-rs) [docs.rs](https://docs.rs/gen-rs) [status](https://github.com/agarret7/gen-rs/actions?query=branch%3Amain) gen-rs is an experimental, research crate for probabilistic programming in Rust. gen-rs supports many features of other Rust-native probabilistic computing frameworks such as [ferric](https://github.com/ferric-ai/ferric), and is written at a lower-level than languages such as [Gen.jl](https://github.com/probcomp/Gen.jl). This library implements the Generative Function Interface [[GFI]](https://github.com/agarret7/gen-rs/blob/main/gen-rs/src/gfi.rs) as specified in the [Gen.jl whitepaper](https://dl.acm.org/doi/10.1145/3314221.3314642) and [Marco Cusumano-Towner's thesis](https://www.mct.dev/assets/mct-thesis.pdf)), and a basic, yet complete set of inference procedures. ## Modeling Features - Generative Function Interface (GFI) compatible - Dynamically-typed `TrieFn` DSL - [Example model implementations](https://github.com/agarret7/gen-rs/blob/main/gen-rs/tests/triefns) ## Inference Features - Importance Sampling - Proposal-based MCMC - Particle Filtering Generate visualizations to `visualizations` with: ```shell python -m venv venv && activate venv/bin/activate && pip install matplotlib cargo test && python visualization/visualizer.py ``` ## Disclaimer Unlike most modern ML systems, probabilistic programming doesn't require a differentiable likelihood; a fast (possibly parallelized) CPU-bound iterator is often sufficient for inference. This aligns well with Rust's principle of "fearless concurrency". However, most embodied (read: practical) modeling efforts still require extensive parameter tuning and Langevin or Hamiltonian Monte Carlo inference moves, to effectively leverage numerical gradients of the local energy landscape in top-down or supervised data processing. Despite Rust being a delightful experience to program in, AD support and GPU acceleration is still somewhat shaky (given the lack of first-class Rust-native tensor libraries), limiting these applications. This project was heavily inspired by [GenTL](https://github.com/OpenGen/GenTL/tree/main) and several more fully-featured projects in the OpenGen ecosystem such as [Gen.jl](https://github.com/probcomp/Gen.jl/tree/master), [GenParticleFilters](https://github.com/probcomp/GenParticleFilters.jl), [SMCP3](https://github.com/probcomp/aistats2023-smcp3), [Bayes3D](https://github.com/probcomp/bayes3d/tree/main), and GenJax.

近期下载者

相关文件


收藏者