-
Can anyone tell me how the NRMSE is calculated in GLuonTS, in particular i am looking for the formula. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
If you have The corresponding code is split across multiple places:
|
Beta Was this translation helpful? Give feedback.
If you have$N$ time series, and a prediction length of $H$ , denote by $x_{i, h}$ the true value of time series $i$ at prediction horizon $h$ , and the corresponding mean forecast by $\hat{x}_{i, h}$ . Then the RMSE is computed as
$$\text{RMSE} = \sqrt{\frac{1}{N}\sum_{i=1}^N \frac{1}{H}\sum_{h=1}^{H} (x_{i, h} - \hat{x}_{i, h})^2}.$$
$$\text{NRMSE} = \frac{\text{RMSE}}{\frac{1}{NH}\sum_i \sum_h |x_{i,h}|}$$
The NRMSE is RMSE normalized by the mean of the absolute true values, i.e.
The corresponding code is split across multiple places:
mse
function:gluonts/src/gluonts/evaluation/metrics.py
Line 55 in 015ff06