# Probabilistic forecasting for spatio-temporal raster data

**URL:** <https://discourse.julialang.org/t/probabilistic-forecasting-for-spatio-temporal-raster-data/98436>\
**Category:** Probabilistic Programming\
**Tags:** statistics, time-series, machine-learning, bayesian-inference, gaussian-process\
**Created:** [May 7, 2023, 11:41am UTC](https://discourse.julialang.org/t/probabilistic-forecasting-for-spatio-temporal-raster-data/98436 "2023-05-07T11:41:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![microlifecc](https://avatars.discourse-cdn.com/v4/letter/m/ed655f/32.png) [@microlifecc](https://discourse.julialang.org/u/microlifecc)\
**Post date:** [May 7, 2023, 11:41am UTC](https://discourse.julialang.org/t/probabilistic-forecasting-for-spatio-temporal-raster-data/98436/1 "2023-05-07T11:41:01Z")

</div>

We have a time series gridded/ratser panel dataset (spatio-temporal). The dataset is in 3D, where each ((x, y, t), where x and y ranges from 1-25 while t ranges from 1-1800 though we’re trying to predict just the next time step) coordinate has a numeric value (such as the sea temperature at that location and at that specific point in time). So we can think of it as a matrix with a temporal component. The dataset is similar to this but with just one channel:

[![Dataset](https://global.discourse-cdn.com/julialang/original/3X/2/6/269761e8838adcdee3686209bb3c3c0ba0dbd0a6.png)](https://i.stack.imgur.com/tP1Lz.png)

We’re trying to predict/forecast the nth time step values for the whole region (i.e., all x, y coordinates in the dataset) given the values for the n-1 time steps and the uncertainty.

Can you all suggest any model/architecture/approach for the same? Is it possible to tackle this with multiple kernels with separate kernels for the spatial covariance and separate for the temporal covariance?

Thanks!

---

<div class="post-metadata">

**Author:** ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Post date:** [May 7, 2023, 11:50am UTC](https://discourse.julialang.org/t/probabilistic-forecasting-for-spatio-temporal-raster-data/98436/2 "2023-05-07T11:50:13Z")

</div>

It really depends on the spatial-temporal resolution. You mentioned that you have temperature as the target variable, it is usually very smooth and seasonal. I had success with [StateSpaceModels.jl](https://github.com/LAMPSPUC/StateSpaceModels.jl), it is very robust and explainable, which is usually something you would like to have in climate/weather studies.

---

<div class="post-metadata">

**Author:** ![theogf](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/theogf/32/1987_2.png) [@theogf](https://discourse.julialang.org/u/theogf)\
**Post date:** [May 7, 2023, 6:44pm UTC](https://discourse.julialang.org/t/probabilistic-forecasting-for-spatio-temporal-raster-data/98436/3 "2023-05-07T18:44:19Z")

</div>

You might be interesting in trying [TemporalGPs.jl](https://github.com/JuliaGaussianProcesses/TemporalGPs.jl), it is specifically designed to work on this kind of problem.
