Replies: 1 comment
-
Finally getting to this --- I don't think this is the intended use case for deterministic trace translators, since it's going to add a whole bunch overhead compared to just implementing the inverse CDF sampling trick in Julia directly. The intended usage for (deterministic) trace translators is to perform SMC between models with different structures (see the paper that introduced the trace translator concept: https://files.sri.inf.ethz.ch/website/papers/pldi18_interemental_inference_for_probabilistic_programs.pdf). |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm trying to simulate/fit a problem where I have access to a numerical CDF, and thought I could use the inverse CDF approach to sample from this distribution in Gen.jl. As a simple test case, let's try to fit a normal distribution, firstly by drawing samples from a normal, and then by drawing uniform samples and using the inverse CDF. I've looked up the documentation on deterministic traces, but I'm unclear where to go next such that I could use
Gen.mh
etc. What are the next steps below? I tried to comment my code throughout.Apart from not knowing how to include a transformed trace inside a
@gen
model, it isn't clear whether the parameters for the transform should come from the trace or passed as parameters when included inside the@gen
macro.Beta Was this translation helpful? Give feedback.
All reactions