BasicTS
BasicTS copied to clipboard
ufunc 'subtract' cannot use operands with types dtype('int64') and dtype('<M8[D]')
您好,我用自己的时序数据, 一列17000行的数据(人数随时间的变化预测),处理数据采用以下代码。 出现了错误:ufunc 'subtract' cannot use operands with types dtype('int64') and dtype('<M8[D]') 请问可能是什么问题,谢谢!
python scripts/data_preparation/mydata/generate_training_data.py
raw time series shape: (17000, 1, 1)
number of training samples:11895
number of validation samples:1699
number of test samples:3399
mean (training data): [[[124.47152696]]]
std (training data): [[[140.87926682]]]
Traceback (most recent call last):
File "/home/x/BasicTS-master/scripts/data_preparation/mydata/generate_training_data.py", line 169, in
When generating the time in day
and day in week
features, you need to write code according to the format of your own dataset. It appears that your dataset does not follow the same format as METR-LA/PEMS-BAY. Maybe you can refer to the script of PEMS04.