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

Using the same model for different data sets #181

Open
howardnewyork opened this issue Jun 1, 2018 · 2 comments
Open

Using the same model for different data sets #181

howardnewyork opened this issue Jun 1, 2018 · 2 comments
Milestone

Comments

@howardnewyork
Copy link

It appears that when you write a Greta model, the data is "bound" to the model. Is it possible to write a model, compile it, and then feed the compiled model different data sets? This is useful if you are running the same model over 100s of datasets.

@goldingn
Copy link
Member

goldingn commented Jun 3, 2018

That will be made possible soon, as we're also planning to enable inference methods that enable using a different minibatch of data at each iteration.

A limitation of that mechanism is that the datasets will have to have identical dimensions. If you want to fit the same model to datasets with different dimensions (e.g. different numbers of observations) the easiest thing would be to write a function to build (and possibly fit) a greta model to a given dataset, then loop over that function feeding the datasets.

@goldingn
Copy link
Member

See this post on the forum for a hacked together implementation of batching. Feedback veery welcome!

@njtierney njtierney added this to the 0.5.0 milestone Jul 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants