-
-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a function to generate prior samples #109
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #109 +/- ##
==========================================
- Coverage 98.50% 98.03% -0.47%
==========================================
Files 10 11 +1
Lines 737 765 +28
Branches 63 69 +6
==========================================
+ Hits 726 750 +24
- Misses 4 5 +1
- Partials 7 10 +3 ☔ View full report in Codecov by Sentry. |
cf670bb
to
c188971
Compare
Decisions regarding the output format will be informed by the constraints that a general-purpose sampling function imposes. Here are some thoughts:
|
d477390
to
d2fdc5f
Compare
We could automatically generate sequential names. Alternatively, we return a list and provide another function(s) that generate other formats, |
Definitely; and we can use the
Also a very viable approach! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This could use a test for the uncovered case in get_rv_updates
, but, other than that, this should be good to go.
b5e3b25
to
51db0a2
Compare
51db0a2
to
fd670d5
Compare
Here we add a utility function to generate prior samples for any variable present in a model. The function should return samples in a format that is convenient for the users. The format is still TBD, although the standard in the Python PPL world seems to be XArray (for compatibility with ArviZ).
Note: it is not necessary to pass the updates to
function
in this case (but we need to make sure to return them as outputs to Scan's inner function), can we just not return them at all to simplify the interface further?Related to #101