Skip to content

align minibatches #2760

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

Merged
merged 3 commits into from
Dec 19, 2017
Merged

align minibatches #2760

merged 3 commits into from
Dec 19, 2017

Conversation

ferrine
Copy link
Member

@ferrine ferrine commented Dec 19, 2017

sometimes rngs are not aligned, so this function can help

@twiecki
Copy link
Member

twiecki commented Dec 19, 2017

LGTM.

@ferrine ferrine merged commit de1b8c8 into pymc-devs:master Dec 19, 2017
@gBokiau
Copy link
Contributor

gBokiau commented Feb 2, 2018

Hi guys,

I'm presuming that in the presence of multiple minibatches in a model, this would allow the same rows to be sampled at each iteration.

Any chance for a quick write up on how this might work?

In particular, is this supposed to be called during model definition, or as a callback of sorts?

@gBokiau
Copy link
Contributor

gBokiau commented Feb 2, 2018

From what I'm gathering this should best be called right before fitting, as model construction (again, purely guessing what I'm observing) might break alignments if some minibatches are used more than once and/or altered, dimshuffled or otherwise transformed in the model declaration.

@ferrine
Copy link
Member Author

ferrine commented Feb 2, 2018

Yes, alignment should be done right before any action that involves them. No need to rerun notebook after occasional minibatch. eval()

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.

3 participants