facebookexperimental / Robyn

Robyn is an experimental, AI/ML-powered and open sourced Marketing Mix Modeling (MMM) package from Meta Marketing Science. Our mission is to democratise modeling knowledge, inspire the industry through innovation, reduce human bias in the modeling process & build a strong open source marketing science community.
https://facebookexperimental.github.io/Robyn/
MIT License
1.08k stars 322 forks source link

robyn_refresh produces only models different from the original #890

Open angelinaparkina opened 6 months ago

angelinaparkina commented 6 months ago

Project Robyn

Describe issue

Hi team Robyn, I have a working model, where some channels were set to 0 by the model. Other models from the same run did set 2 or 1 more channels to 0, which did not seem realistic. So I chose the one that had the minimum amount of channels being set to 0, and most realistic ROIs.

After choosing the best model, I reproduced it multiple times to run the budget allocator. The ROIs from the reproduce function were the same as in the original model.

Now, I would like to refresh the model with 30 new weeks of data (original model has 173 weeks). When I do that with the refresh function, two channels are set to 0, which had an effect in the original model. For a test, I tried to refresh it with only two weeks of data, which produces the same effect - two channels are set to 0 in all the model variants. Since that does not seem realistic from the channels perspective, I would want to get more or less similar results to the original model, at least in the sense that the channels that had an effect before still do, even if we update the model with 2 weeks of data.

A couple of things that could be relevant here:

What other reasons can there be for such a result?

Provide reproducible example

I'm attaching the results of the original model (upper), and the example of a refreshed model (lower) (with 2 weeks).

image image

The code I am using for refresh:

Robyn <- robyn_refresh( json_file = json_file, dt_input = data, dt_holidays = prophet, refresh_steps = 2, refresh_mode = "manual", refresh_iters = 2000, refresh_trials = 3, version_prompt=FALSE, plot_folder = '' ) I'm also including hyperparameters from the refresh + hyperparameters for the original model. hyperparameters_refresh_issue.xlsx

Let me know if anything else is needed to debug.

Environment & Robyn version

Make sure you're using the latest Robyn version before you post an issue.

ghltk commented 4 months ago

@ddempseyr @gufengzhou Hi there, I am encountering this issue as well. Is there any update here?

Thank you!

gufengzhou commented 4 months ago

FYI I've shipped an update to refresh and hopefully the results are now more consistent. Please update the package and test

amanrai2508 commented 1 month ago

Hi @gufengzhou

I am facing the same type of issues while doing refresh. Version : 3.10.7 (I think in 3.10.6 it worked)

This image is after the refresh of the model (have added 2 weeks in the refreshed file): 1_142_3

This image is for the main model(solid) : 3_629_6