About Semantic Scale Repetition
Thank you for your great work! I am confused about the semantic scale repetition operation. In each scale, does the model perform residual quantization and residual re-computation at every repetition? If so, would this cause the input features and predicted indices to differ across repetitions within the same scale? During training, the model randomly selects one of the repetitions as input in each scale—is that correct?
@drx-code Thank you for your interest!
- In each scale, does the model perform residual quantization and residual re-computation at every repetition?
Yes, at each scale, the model performs both residual quantization and residual re-computation for every repetition. This is also beneficial for reconstruction.
- If so, would this cause the input features and predicted indices to differ across repetitions within the same scale?
That’s correct. Since residual quantization is applied repeatedly within the same scale, both the input features and the predicted indices can vary across different repetitions.
- During training, the model randomly selects one of the repetitions as input in each scale—is that correct?
Yes, this is a training strategy we use. We pre-extract all residual quantization features according to the repetition and scale schedule. However, training on all repetitions simultaneously would dramatically increase the sequence length and computational cost. Therefore, for each sample in every training batch, we randomly select one repetition per scale for training.
I hope this answers your questions!
Thank you for your reply! I now fully understand the semantic scale repetition mechanism.
Another question that comes to mind is: Are some scales randomly dropped during the training of both the generator and the tokenizer? If so, how does the generator benefit from this random scale dropping?
Additionally, can the model generate videos with a variable number of frames, for example, with generation_duration=12 or 15?
Thanks again!
@drx-code hi,
- Are some scales randomly dropped during the training of both the generator and the tokenizer?
Yes, we also randomly drop scales during the training of the tokenizer. This approach is described in our paper "Stochastic Quantizer Depth " section.
- If so, how does the generator benefit from this random scale dropping?
The main benefit is improved training efficiency. In practice, expanding all repetition scales into a single sequence would require multi-GPU parallelization and significantly increase training complexity and resource usage. Our approach makes training much more efficient, as it is unnecessary to process every scale in each iteration. Additionally, during high-resolution training, we do not train on all scales, especially for the larger ones. Instead, we randomly select a subset of scales from all available scales to form a fixed-length sequence for packing. The earlier scales are more important and require more training, so by focusing on a subset, we can allocate resources more effectively.
- Additionally, can the model generate videos with a variable number of frames, for example, with
generation_duration=12 or 15?
Yes, the model is inherently capable of generating videos with a variable number of frames, , but achieving good results requires additional long video training. To efficiently support the generation of longer videos, we have trained an additional interactive model. You can try this feature using the script tools/infer_interact_480p.py to see the results.
Thank you so much! Your patient and meticulous reply has fully clarified my confusion. I will try tools/infer_interact_480p.py for the generation of longer videos.
Thanks again for your great work!