You have two basic alternatives:


Use padding (& packing). 20 That’s a standard practice to handle batch sequences of different lengths.
Organize your batches in such way that all sequences withing one batch have the same length. 8