pymc.编译_pymc#

pymc.compile_pymc(inputs, outputs, random_seed=None, mode=None, **kwargs)[源代码]#

始终启用专门化的 pymc 重写来使用 pytensor.function

此函数还确保图中的随机变量所使用的共享 RandomState/Generator 在每次调用时都会更新,以确保独立抽取。

参数:
输入: TensorVariables 列表, 可选

编译后的 PyTensor 函数的输入

outputs: TensorVariables 列表, 可选

编译后的 PyTensor 函数的输出

random_seed: int, array-like of int 或 SeedSequence, 可选

用于覆盖图中任何 RandomState/Generator 共享变量的种子。如果未指定,原始共享变量的值仍将被覆盖。

模式: 可选

PyTensor 模式用于编译函数