There is a way to do so when you are tokenising your data by setting the max_length parameter;
train_encodings = tokenizer(seq_train, truncation=True, 
                         padding=True, max_length=1024)