The official implementation of the Time Series Attention Transformer (TSAT).
main.py
: main TSAT model interface with training and testingTSAT.py
: with TSAT class implementationutils.py
: utility functions and dataset parameterdataset_TSAT_ETTm1_48.py
: generate graph from dataset ETTm1Download the Electricity Transformer Temperature Dataset from https://github.com/zhouhaoyi/ETDataset. Uncompress them and move the .csv to the Data
folder.
The Electricity consumption dataset can be found on https://github.com/laiguokun/multivariate-time-series-data.
The parameters setting can be found in utils.py
.
l_backcast
: lengths of backcastd_edge
: number of IMF usedd_model
: the time embedding dimensionN
: number of Self_Attention_Blockh
: number of head in Multi-head-attentionN_dense
: number of linear layer in Sequential feed forward layersn_output
: number of output (lengths of forecast $\times$ number of node)n_nodes
: number of node (aka number of time series)lambda
: the initial value of the trainable lambda $\alpha_i$dense_output_nonlinearity
the nonlinearity function in dense output layerDependencies can be installed using the following command:
pip install -r requirements.txt
If you have any questions, please feel free to contact William Ng (Email: william.ng@koiinvestments.com).