tsinghua-fib-lab / UniST

Official implementation for "UniST: A Prompt-Empowered Universal Model for Urban Spatio-Temporal Prediction" (KDD 2024)
95 stars 11 forks source link

模型推理问题 #13

Open kakaroy123 opened 2 months ago

kakaroy123 commented 2 months ago

作者你好!最近在复现论文,得到模型后想跑新数据的预测结果,必须要把每天数据处理为每半小时1次,一天48次数据么?还有推理的时候怎么获取到每个网格的预测值呢?

YuanYuan98 commented 2 months ago

Hello! It's not necessary to format the data into half-hour intervals (48 time slots per day). You can use separate temporal embedding modules that are capable of encoding data at different temporal resolutions.

As for the inference process, in the case of short-term prediction, the input data format should indeed be a sequence of 12 time slots, which corresponds to the combined duration of historical (6 slots) and future (6 slots) data for a 6-to-6 prediction scenario. The model outputs predictions for a sequence of 12 slots as well. If your prediction horizon is set to 6 time slots, you can simply extract the last 6 slots from the model's output to get your prediction results.