# Training, inference, and use of future data

**URL:** <https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272>\
**Category:** Water Supply Forecast Rodeo\
**Created:** [November 12, 2023, 10:12am UTC](https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272 "2023-11-12T10:12:59Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![kamarain](https://avatars.discourse-cdn.com/v4/letter/k/bcef8e/32.png) [@kamarain](https://community.drivendata.org/u/kamarain)\
**Post date:** [November 12, 2023, 10:12am UTC](https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272/1 "2023-11-12T10:12:59Z")

</div>

Are we allowed to use models which are trained to all of the years in train.csv to predict all of the test years, just making sure at the inference stage that the time stamps of predictor data are earlier than each of the issue dates? Or is this considered as using future data?

For example, when predicting year **2005** , can I use a model trained with years 1890–2004, **2006** , **2008** , **2010** , **2012** , … ?

---

<div class="post-metadata">

**Author:** ![jayqi](https://yyz2.discourse-cdn.com/flex028/user_avatar/community.drivendata.org/jayqi/32/924_2.png) [@jayqi](https://community.drivendata.org/u/jayqi)\
**Post date:** [November 12, 2023, 1:46pm UTC](https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272/2 "2023-11-12T13:46:53Z")

</div>

Hi @kamarain,

Yes, that is correct. Hydrologists generally consider the water supply across years to be independent enough to train models in this way. This approach is necessary in order to have sufficient data for training and evaluation.

---

<div class="post-metadata">

**Author:** ![tomwetherell](https://yyz2.discourse-cdn.com/flex028/user_avatar/community.drivendata.org/tomwetherell/32/1597_2.png) [@tomwetherell](https://community.drivendata.org/u/tomwetherell)\
**Post date:** [November 12, 2023, 10:24pm UTC](https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272/3 "2023-11-12T22:24:12Z")

</div>

> just making sure at the inference stage that the time stamps of predictor data are earlier than each of the issue dates

Just to confirm, if I was predicting the year 2005 on issue date March 8th, I could use a model trained using **all** data from the years 1890, 2006, 2008, and so on - not just the data from before March 8th?

And of course input to my model would be data from October 2004 - March 8th 2005.

---

<div class="post-metadata">

**Author:** ![jayqi](https://yyz2.discourse-cdn.com/flex028/user_avatar/community.drivendata.org/jayqi/32/924_2.png) [@jayqi](https://community.drivendata.org/u/jayqi)\
**Post date:** [November 13, 2023, 2:32pm UTC](https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272/4 "2023-11-13T14:32:32Z")

</div>

> [@tomwetherell](#):
>
> Just to confirm, if I was predicting the year 2005 on issue date March 8th, I could use a model trained using **all** data from the years 1890, 2006, 2008, and so on - not just the data from before March 8th?

Yes, that is correct.

> And of course input to my model would be data from October 2004 - March 8th 2005.

It should be data through March 7, 2005. This clarification was made in an [announcement on November 2](https://www.drivendata.org/competitions/254/reclamation-water-supply-forecast-dev/announcements/#use-of-future-feature-data-clarification).

---

<div class="post-metadata">

**Author:** ![jimking100](https://avatars.discourse-cdn.com/v4/letter/j/9d8465/32.png) [@jimking100](https://community.drivendata.org/u/jimking100)\
**Post date:** [November 21, 2023, 6:55pm UTC](https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272/5 "2023-11-21T18:55:38Z")

</div>

Hi,  
With the latest announcements about the use of future data I’d like to just confirm that we may still use all the training data including 2006, 2008, 2010…2022 for training our models - or did this change?  
Thanks

---

<div class="post-metadata">

**Author:** ![jayqi](https://yyz2.discourse-cdn.com/flex028/user_avatar/community.drivendata.org/jayqi/32/924_2.png) [@jayqi](https://community.drivendata.org/u/jayqi)\
**Post date:** [November 22, 2023, 4:46pm UTC](https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272/6 "2023-11-22T16:46:14Z")

</div>

Hi @jimking100,

Yes, that is correct.

In this challenge, forecast years are treated as independent observations. We are not imposing time series restrictions (e.g., future years used in training) across forecast years. This means that it’s fine, for example, to have a model trained on training data including the 2006 forecast year be used to issue predictions for the 2005 forecast year. In treating forecast years _independently_, a prediction for one forecast year should generally not depend on being a specific year or overlap/include data from other forecast years.

The time series restriction applies within a forecast year: your model should only use past data relative to that issue date _within_ that forecast year.

---

<div class="post-metadata">

**Author:** ![jitters](https://avatars.discourse-cdn.com/v4/letter/j/f08c70/32.png) [@jitters](https://community.drivendata.org/u/jitters)\
**Post date:** [November 23, 2023, 1:19pm UTC](https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272/7 "2023-11-23T13:19:55Z")

</div>

Assuming the years are independent, would it then be possible to use historic average streamflows of a given catchment (excluding the forecast year in question) as a predictor?

---

<div class="post-metadata">

**Author:** ![jayqi](https://yyz2.discourse-cdn.com/flex028/user_avatar/community.drivendata.org/jayqi/32/924_2.png) [@jayqi](https://community.drivendata.org/u/jayqi)\
**Post date:** [November 29, 2023, 10:14pm UTC](https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272/8 "2023-11-29T22:14:30Z")

</div>

Split this topic on November 29, 2023, 10:14pm UTC

A post was split to a new topic: [Naturalized flow data for sites other than the 26](https://community.drivendata.org/t/naturalized-flow-data-for-sites-other-than-the-26/9394)

---

<div class="post-metadata">

**Author:** ![jayqi](https://yyz2.discourse-cdn.com/flex028/user_avatar/community.drivendata.org/jayqi/32/924_2.png) [@jayqi](https://community.drivendata.org/u/jayqi)\
**Post date:** [November 29, 2023, 11:24pm UTC](https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272/9 "2023-11-29T23:24:18Z")

</div>

Hi @jitters,

You may calculate “historic” average streamflows using data from training years. The reason I put quotes around “historic” is that you can include any year 2004 and earlier, and training years (even years 2006–2022)—such an average may include years that are in the future of years in the test set. This can be used as a feature or be used as part of the derivation of some other feature.

However, such an average should not include any years from the test set.

---

<div class="post-metadata">

**Author:** ![jayqi](https://yyz2.discourse-cdn.com/flex028/user_avatar/community.drivendata.org/jayqi/32/924_2.png) [@jayqi](https://community.drivendata.org/u/jayqi)\
**Post date:** [December 6, 2023, 3:22am UTC](https://community.drivendata.org/t/training-inference-and-use-of-future-data/9272/10 "2023-12-06T03:22:53Z")

</div>

Hi everyone,

We’ve updated the problem description to more clearly explain the concepts discussed in this thread. We’ve also added an FAQ section to address specific questions in more detail. See [this announcement](https://www.drivendata.org/competitions/254/reclamation-water-supply-forecast-dev/announcements/#time-and-data-use-clarification-and-faq).

Please let us know if you continue to have questions about the modeling setup.
