Since you have two free dimensions, it’s not clear to me how you’ll be able to use torch.concat either. Usually you would have to do some sort of padding if you need one neat tensor and then join the uniform tensors along the batch axis (either by torch.concating a uniformly 1-D axis or by torch.stacking to create a new batch axis - looks like the former is what you need). Usually I would pad the temporal dimension of the videos (I guess that’s A?) but you say that C varies too, so you would have to do something even more clever.  I’ve always done padding inside a custom collate function.