Can torchtext's BucketIterator pad all batches to the same length?
I recently started using torchtext to replace my glue code and I'm running into an issue where I'd like to use an attention layer in my architecture. In order to do this, I need to know the maximum sequence length of my training data. 

The problem is that torchtext.data.BucketIterator does padding on a per-batch basis:

# All 4 examples in the batch will be padded to maxlen in the batch
train_iter = torchtext.data.BucketIterator(dataset=train, batch_size=4)


Is there some way to ensure that all training examples are padded to the same length; i.e., the maxlen in training?

When instantiating a torchtext.data.Field, there's an optional keyword argument called fix_length which, when set, defines the length to which all samples will be padded; by default it is not set which implies flexible padding.
