{
  "id": 47169,
  "title": "Shall we make predication for each (store, item) separately?",
  "url": "/competitions/favorita-grocery-sales-forecasting/discussion/47169",
  "author_name": "",
  "post_date": "2018-01-09T16:49:48.661807600Z",
  "votes": null,
  "comment_count": 4,
  "views": 0,
  "content": "<p>I have checked some kernels. It seems many of them just mix all the stores and items together and then feed these data (after some feature engineering) into a model like XGBoost. But I am confused and hope to get some help here.</p>\n\n<p>Does it make sense by mixing them up? In a decision tree based model, the *store_nbr* and *item_nbr* may be used to split nodes. If so, why don't we just train a model for each <strong>(store, item)</strong> pair? After all, we are required to predict for each <strong>(store, item)</strong> separately.</p>",
  "messages": [
    {
      "id": "266760",
      "postDate": "01/09/2018 16:49:48",
      "content": "<p>I have checked some kernels. It seems many of them just mix all the stores and items together and then feed these data (after some feature engineering) into a model like XGBoost. But I am confused and hope to get some help here.</p>\n\n<p>Does it make sense by mixing them up? In a decision tree based model, the *store_nbr* and *item_nbr* may be used to split nodes. If so, why don't we just train a model for each <strong>(store, item)</strong> pair? After all, we are required to predict for each <strong>(store, item)</strong> separately.</p>",
      "rawMarkdown": "I have checked some kernels. It seems many of them just mix all the stores and items together and then feed these data (after some feature engineering) into a model like XGBoost. But I am confused and hope to get some help here.\n\nDoes it make sense by mixing them up? In a decision tree based model, the *store_nbr* and *item_nbr* may be used to split nodes. If so, why don't we just train a model for each **(store, item)** pair? After all, we are required to predict for each **(store, item)** separately.",
      "votes": null
    },
    {
      "id": "266796",
      "postDate": "01/09/2018 19:33:42",
      "content": "<p>In my opinion, if you use store_nbr and item_nbr to split nodes, it would be too specific and thus there would be no enough training data to train such a specific (store_nbr, item_nbr) nodes. In other word, mixing them up can make the model more generative.</p>",
      "rawMarkdown": "In my opinion, if you use store_nbr and item_nbr to split nodes, it would be too specific and thus there would be no enough training data to train such a specific (store_nbr, item_nbr) nodes. In other word, mixing them up can make the model more generative.",
      "votes": null
    },
    {
      "id": "266881",
      "postDate": "01/10/2018 03:55:19",
      "content": "<p>Hi, ZedYeung. Thanks for your reply. Yes, you are right. If we split the training data according to (store_nbr, item_nbr), there will be only around 350 samples on average for each (store_nbr, item_nbr). However, it is still a little confusing. In traditional time series analysis like the ARIMA model, we need to split these data, each time series for each (store_nbr, item_nbr), right?</p>",
      "rawMarkdown": "Hi, ZedYeung. Thanks for your reply. Yes, you are right. If we split the training data according to (store_nbr, item_nbr), there will be only around 350 samples on average for each (store_nbr, item_nbr). However, it is still a little confusing. In traditional time series analysis like the ARIMA model, we need to split these data, each time series for each (store_nbr, item_nbr), right?",
      "votes": null
    },
    {
      "id": "267191",
      "postDate": "01/10/2018 20:06:13",
      "content": "<p>I have this concerns as well. I was thinking about if we have a separate model for each (store, item) pair, for example one LSTM for each pair's time series, we would end up having a large number of LSTMs. Just feel it's not right to have that many models. </p>",
      "rawMarkdown": "I have this concerns as well. I was thinking about if we have a separate model for each (store, item) pair, for example one LSTM for each pair's time series, we would end up having a large number of LSTMs. Just feel it's not right to have that many models.",
      "votes": null
    },
    {
      "id": "267479",
      "postDate": "01/11/2018 13:16:34",
      "content": "<p>I tried this, but results improved only for small number of pairs with high average demand. I think we just haven't enough data for only one pair in general case.</p>",
      "rawMarkdown": "I tried this, but results improved only for small number of pairs with high average demand. I think we just haven't enough data for only one pair in general case.",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 266796,
      "author_name": "yedthon",
      "author_url": "",
      "post_date": "01/09/2018 19:33:42",
      "content": "<p>In my opinion, if you use store_nbr and item_nbr to split nodes, it would be too specific and thus there would be no enough training data to train such a specific (store_nbr, item_nbr) nodes. In other word, mixing them up can make the model more generative.</p>",
      "votes": null,
      "replies": [
        {
          "id": 266881,
          "author_name": "shuhuagao",
          "author_url": "",
          "post_date": "01/10/2018 03:55:19",
          "content": "<p>Hi, ZedYeung. Thanks for your reply. Yes, you are right. If we split the training data according to (store_nbr, item_nbr), there will be only around 350 samples on average for each (store_nbr, item_nbr). However, it is still a little confusing. In traditional time series analysis like the ARIMA model, we need to split these data, each time series for each (store_nbr, item_nbr), right?</p>",
          "votes": null,
          "replies": []
        }
      ]
    },
    {
      "id": 267191,
      "author_name": "bdeng3",
      "author_url": "",
      "post_date": "01/10/2018 20:06:13",
      "content": "<p>I have this concerns as well. I was thinking about if we have a separate model for each (store, item) pair, for example one LSTM for each pair's time series, we would end up having a large number of LSTMs. Just feel it's not right to have that many models. </p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 267479,
      "author_name": "ilyalos",
      "author_url": "",
      "post_date": "01/11/2018 13:16:34",
      "content": "<p>I tried this, but results improved only for small number of pairs with high average demand. I think we just haven't enough data for only one pair in general case.</p>",
      "votes": null,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "266760": "I have checked some kernels. It seems many of them just mix all the stores and items together and then feed these data (after some feature engineering) into a model like XGBoost. But I am confused and hope to get some help here.\n\nDoes it make sense by mixing them up? In a decision tree based model, the *store_nbr* and *item_nbr* may be used to split nodes. If so, why don't we just train a model for each **(store, item)** pair? After all, we are required to predict for each **(store, item)** separately.",
    "266796": "In my opinion, if you use store_nbr and item_nbr to split nodes, it would be too specific and thus there would be no enough training data to train such a specific (store_nbr, item_nbr) nodes. In other word, mixing them up can make the model more generative.",
    "266881": "Hi, ZedYeung. Thanks for your reply. Yes, you are right. If we split the training data according to (store_nbr, item_nbr), there will be only around 350 samples on average for each (store_nbr, item_nbr). However, it is still a little confusing. In traditional time series analysis like the ARIMA model, we need to split these data, each time series for each (store_nbr, item_nbr), right?",
    "267191": "I have this concerns as well. I was thinking about if we have a separate model for each (store, item) pair, for example one LSTM for each pair's time series, we would end up having a large number of LSTMs. Just feel it's not right to have that many models.",
    "267479": "I tried this, but results improved only for small number of pairs with high average demand. I think we just haven't enough data for only one pair in general case."
  },
  "source": "meta"
}