Skip to content
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

feat: add api compat arg to NS.get_samples #1880

Merged
merged 3 commits into from
Oct 12, 2024

Conversation

nstarman
Copy link
Contributor

@nstarman nstarman commented Oct 6, 2024

The standard API, which tools like arviz rely on, requires the argument group_by_chain.
See

def get_samples(self, group_by_chain=False):
.
This PR adds the kwarg as a no-op.

Fixes #1879

@fehiepsi
Copy link
Member

fehiepsi commented Oct 6, 2024

if group_by_chain is true, I guess we need to add singleton dimension in front. Otherwise we can raise error if it is true.

@nstarman
Copy link
Contributor Author

nstarman commented Oct 6, 2024

I like the grouping by chain suggestion. Arviz wants that for the shape.

@nstarman
Copy link
Contributor Author

nstarman commented Oct 7, 2024

The CI error is unrelated and blocking the actual unit tests. Happy to rebase when a sphinx-fixing PR is merged.

@juanitorduz
Copy link
Contributor

The CI error is unrelated and blocking the actual unit tests. Happy to rebase when a sphinx-fixing PR is merged.

Pushing a fix in #1882

@fehiepsi
Copy link
Member

fehiepsi commented Oct 9, 2024

The fix is merged thanks to @juanitorduz!

@nstarman
Copy link
Contributor Author

👍. Rebased.

@nstarman
Copy link
Contributor Author

@fehiepsi, is this good to go in?

@fehiepsi fehiepsi merged commit aa860f7 into pyro-ppl:master Oct 12, 2024
4 checks passed
@nstarman nstarman deleted the jaxns-group-by-chain branch October 12, 2024 18:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

get_samples does not accept kwarg "group_by_chain"
3 participants