How to fine tune Time Series Transformer?

I am trying to fine tune a time series transformer model. While applying trainer.train() I always received errors, the most recent one is: “IndexError: Invalid key: 0 is out of bounds for size 0”. I searched and found several fine tune huggingface model examples in text mining field, not in time series transformer. Can anyone give some advice? Thank you!