src/transformers/trainer_pt_utils.py/LengthGroupedSampler/__iter__
class LengthGroupedSampler:    def __iter__(self):
        indices = get_length_grouped_indices(self.lengths, self.batch_size, generator=self.generator)
        return iter(indices)