Community Conundrums are live! Learn more

Forecast Plugin - partition dataset

Level 1
Forecast Plugin - partition dataset

Your forecast plugin looks great, but the flow takes all values as a single timeseries. Is it possible to specify a column to partition the data on? It would be nice to train and predict forecast models for multiple entities in one go.

7 Replies
Dataiker
Dataiker

Hey,



Thanks for your interest in this recent plugin release.



If you want run the recipes to get multiple forecasting models per category (e.g. per product or store), you will need partitioning. That requires to have all datasets partitioned by 1 dimension for the category, using the discrete dimension feature in Dataiku. If the input data is not partitioned, you can use a Sync recipe to repartition it, as explained in this article.



Hope it helps,



Alex

0 Kudos
Dataiker
Dataiker
Hi, I have an example project to demonstrate the use of partitions with the plugin. Is there an email address I could send it to you?
Level 1

thanks for this plugin.  I am also interested to see some example on how to work with partitions and your plugin 

0 Kudos
Dataiker
Dataiker

Hi,

We are working on a public example of a forecasting project with partitions. It will be published this month on https://gallery.dataiku.com/home/.

In the meantime, this video offers a good introduction to partitioning in DSS: https://www.youtube.com/watch?v=yULLxeqx3gI

Cheers,

Alex Combessie

Dataiku Data Science Studio Free Training #15, with Jed Dougherty (Data scientist). This free training was recorded on May 11th, 2016. Get started with the f...
Level 2
Hello Alex,
I'm facing the same issue as Rik. I' ve partioned a dataset into 10 partitions according to an ID column. Now I would like to apply the forecast recipe to each of them.
Could you tell me where exactly I have to enter this pyrhon code and where the list of partitions is stored?
0 Kudos
Dataiker
Dataiker
Indeed there is no visual way in the partitioning menu of a recipe (of this plugin or any other recipe) to select all partitions. To do so, you would need an additional step to compute the complete list of partitions and store it as a project variable. Here is a piece of boilerplate code in python to do so:

combinations = np.unique(df["store_department"])
combinations_str = "/".join(combinations)

client = dataiku.api_client()
project = client.get_project(dataiku.default_project_key())
variables = project.get_variables()
variables["standard"]["store_department_combinations"] = combinations_str
project.set_variables(variables)

Then you can copy paste the /-separated list of partitions in the partition menu of the plugin recipe.
0 Kudos
Level 1
Author
Thanks for your quick reply. I've tried rebuilding the flow with partitioning and that indeed works.

Maybe it's more of a general question: can you run a recipe for all partitions in the dataset? I could not find instructions on how to do so in the manual or in this QA section. Manually specifying 10's or 100's of partitions is not practical, if technically possible at all (?).

I was hoping to to find a feature that let's me to this in this plugin itself. Any help in scaling this up to more than a couple of entities would be very helpful.
0 Kudos
Labels (2)