prio-data/viewser

Model definition API

Closed this issue · 2 comments

Set up an API that, like Queryset definitions, makes it possible to define models through a simple API.

The "model API" combines everything on offer in ViEWS code, letting users

  1. Fetch a queryset
  2. Train the model
  3. Store the model centrally for later reference
model = Model(
   name="my_model",
   queryset="my_queryset",
   prediction_range=16, # (steps 1, 2 ... 16)
   estimator = RandomForestClassifier(),
   periodization = "my_periodization"
)
model.fetch()
model.predictions # fetches or produces and stores

After discussing this on Slack, we're going with a simpler "toolkit" approach. This won't be implemented.