thuml / Autoformer

About Code release for "Autoformer: Decomposition Transformers with Auto-Correlation for Long-Term Series Forecasting" (NeurIPS 2021), https://arxiv.org/abs/2106.13008
MIT License
2k stars 429 forks source link

Check the correlation calculation code in metrics.py line 10 #102

Closed 943fansi closed 1 year ago

943fansi commented 2 years ago

d = np.sqrt(((true - true.mean(0)) ** 2 * (pred - pred.mean(0)) ** 2).sum(0)) maybe d = np.sqrt(((true - true.mean(0)) ** 2).sum(0) * ((pred - pred.mean(0)) ** 2).sum(0))?

wuhaixu2016 commented 1 year ago

Thanks for this issue, we have fixed this bug in the latest commit:https://github.com/thuml/Autoformer/commit/9d67034cf9f5b049d0a3ea436c10b834939b1635.