We present here a new probabilistic inference algorithm that gives exact results in the domain of discrete probability distributions. This algorithm, named the Statues algorithm, calculates the marginal probability distribution on probabilistic models defined as direct acyclic graphs. These models are made up of well-defined primitives that allow to express, in particular, joint probability distributions, Bayesian networks, discrete Markov chains, conditioning and probabilistic arithmetic. The Statues algorithm relies on a variable binding mechanism based on the generator construct, a special form of coroutine; being related to the enumeration algorithm, this new algorithm brings important improvements in terms of efficiency, which makes it valuable in regard to other exact marginalization algorithms. After introduction of several definitions, primitives and compositional rules, we present in details the Statues algorithm. Then, we briefly discuss the interest of this algorithm compared to others and we present possible extensions. Finally, we introduce Lea and MicroLea, two Python libraries implementing the Statues algorithm, along with several use cases. A proof of the correctness of the algorithm is provided in appendix.
翻译:我们在此提出一种新的概率推算算法, 给离散概率分布领域带来准确结果。 这个算法名为 Statues 算法, 计算了直接环绕图的概率模型的边际概率分布。 这些模型由定义明确的原始模型组成, 特别可以表达联合概率分布、 巴伊西亚网络、 离散的Markov 链、 调节和概率计算。 统计算法依赖于基于发电机构造的可变绑定机制, 一种特殊的共生法形式; 与查点算法有关, 这一新算法在效率方面带来重要的改进, 使得它对于其他精确的边缘化算法很有价值。 在引入了几个定义、 原始和构成规则之后, 我们详细介绍了 Statue 算法。 然后, 我们简要地讨论了该算法与其他算法相比的兴趣, 我们提出可能的扩展。 最后, 我们介绍两个执行 Statue 算法的Python 图书馆, 以及几个使用的案例。 一种算法的正确性证据在附录中提供。