[feat] GenRL: add explicit HPSv3 VideoAlign recipes - #1405
Conversation
|
There was a problem hiding this comment.
Code Review
This pull request updates the training configuration files for GenRL/Video GRPO with Wan 2.1 T2V 1.3B, adjusting hyperparameters for full fine-tuning, updating dataset paths, and introducing new parameters. However, several of the newly added configuration parameters—including accumulate_ppo_microbatches, loss_reweighting: flash_tgr, optimizer_step_per_timestep, log_post_update_kl, and update_interval for the EMA callback—are not supported or implemented in the underlying training code. These unsupported parameters should be removed or corrected to prevent runtime errors and silent failures.
| # Sample multiple rollout microbatches, average their PPO losses, then | ||
| # apply one optimizer update. This reduces reward/advantage variance. | ||
| num_batches_per_epoch: 4 | ||
| accumulate_ppo_microbatches: true |
There was a problem hiding this comment.
The parameter accumulate_ppo_microbatches is not parsed or implemented in GenRLMethod (see fastvideo/train/methods/rl/genrl.py). Currently, the training loop in _ppo_train performs an optimizer step and zeros gradients for every micro-batch in batched_list rather than accumulating gradients across them. This means the behavior described in the comment (averaging PPO losses and applying one optimizer update) is not actually happening.
# Sample multiple rollout microbatches. Note: gradient accumulation across
# microbatches is not currently supported by the training method.
num_batches_per_epoch: 4| # Flash-GRPO-style temporal gradient rectification: avoid the large | ||
| # LongCat sigma/dt multiplier while debugging full-FT stability. | ||
| loss_reweighting: flash_tgr | ||
| loss_reweighting_clip: null |
There was a problem hiding this comment.
The loss_reweighting value "flash_tgr" is not implemented in GenRLMethod._ppo_train (see fastvideo/train/methods/rl/genrl.py). Only "longcat" is supported; any other value will silently default to rw_scale = 1.0 (no reweighting). If temporal gradient rectification is intended, it needs to be implemented in the training method first. Otherwise, set this to null to make it clear that no reweighting is applied.
# No loss reweighting is applied (flash_tgr is not implemented in the training method).
loss_reweighting: null
loss_reweighting_clip: null| ema: | ||
| decay: 0.9 | ||
| start_iter: 0 | ||
| update_interval: 8 |
There was a problem hiding this comment.
The EMACallback class (defined in fastvideo/train/callbacks/ema.py) does not accept an update_interval parameter in its __init__ method, nor does it support **kwargs. Passing update_interval: 8 here will likely cause a TypeError at startup when the callback is instantiated. Additionally, the callback currently updates the EMA on every single step once started, ignoring any interval setting. You should remove this parameter.
ema:
decay: 0.9
start_iter: 0Extracted from hao-ai-lab#1391. Renames the LongCat-labelled recipe to reflect the reward setup. GenRL-Stack: 6/6
392fdda to
46f3937
Compare
Extracted from #1391.
GenRL-Stack: 6/6
Purpose
Update GenRL example recipes after the underlying reward/runtime/PPO/LoRA changes are split into focused PRs.
This also renames the previous LongCat-labelled config to avoid confusion with the actual LongCat-Video model. The recipe remains derived from GenRL's LongCat-style setup, but the filename now reflects the reward stack.
Fixes #
Changes
GenRL/datasets/....genrl_wan2.1_t2v_1.3B_longcat.yamltogenrl_wan2.1_t2v_1.3B_hpsv3_videoalign.yaml.Test Plan
Test Results
Test output