Repository navigation
Conversation
This was referenced Nov 18, 2026
Open
eval/ocr_test goes from 0.6003 to 0.8303 over the recipe's 200 rollouts, with one eval at 0.696 after 160. The page says to pick a checkpoint by its eval.
On a 1000-rollout run of these settings eval/ocr_test is 0.830 after 200 rollouts and 0.948 after 600; the 400 rollouts after that add about 0.01.
eval/ocr_test goes from 0.6003 to 0.9475 over the recipe's 600 rollouts and lies between 0.930 and 0.975 from rollout 700 to 1000. The page lists the drops along the way.
Past 200 rollouts the OCR reward keeps rising because the scene is erased: the detail left in the eval images falls to a fifth by rollout 320, and from 800 on they are text on an empty background. The reward is OCR alone and the recipe has no KL to the base model.
The results section pairs eval/ocr_test with the detail left in the logged eval images and says which part of the curve is a real gain.
The last rollout always saves, and a `--debug-rollout-only` actor has loaded no model: the frozen-weights control the H3 Image page documents ran its 60 rollouts and then failed in `save_model` with an AttributeError, before the rollout manager was disposed.
`--diffusion-eval-num-steps 6` repeats the fallback to `--diffusion-num-steps`, and the family's own error tells a user to drop it; `--diffusion-log-prob-no-const` is forced on for cps. The prompt directory is named as the H3 recipe names it, and the docstring words the cost of gradient checkpointing as the page does.
…d correct the page's numbers The page called the first 180 rollouts clean. The scene is there, but from about 140 rollouts the logged eval images carry a repeating texture on smooth regions, which the detail measure cannot see; the page says so, and says what the 200-rollout endpoint is. "The drops in the eval are the scene coming back" holds for the drop at 400 only. Smaller corrections: detail falls to a quarter, not a fifth; the resolver matches a substring; the recipe syncs adapters over IPC without merging them; a few figures read off the logs.
…give the recipe window's own numbers - `--deterministic-mode` reaches only the trainer; the control and a run share prompts and noise through the fixed `--rollout-seed` and the unshuffled prompt order. - The alignment metric was quoted over 1000 rollouts, where it falls as the scene fades. Over the recipe's 200 it stays between 0.021 and 0.025. - "20-47% clipped before any update" included a second optimizer step; on first steps it is 20-38%. - The control command no longer needs `--save-interval 100000` now that a rollout-only run skips the save. - The recipe's docstring carries the texture caveat the page leads with.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
[H3-Image 4/4] Stacked on #395. The 8-GPU recipe for MiniMax-H3-Image, t2i Flow-GRPO + OCR with LoRA, and its model page.
Stack:
main<- #393 (step index) <- #394 (loader) <- #395 (family) <- #400 (recipe and model page) and #410 (full-weight training), both on #395.The recipe's rollouts need sgl-project/sglang#51113, which is not in
sglang-milesyet:ci-sglang-pr: #51113
What
scripts/run_diffusion_grpo_h3_image_ocr_8gpu.py: FSDP DP=8 colocated with four TP2 rollout engines on 8 GPUs. 512x512, OCR reward, 8 prompts x 16 samples and 2 optimizer steps per rollout, LoRA rank 64 synced over CUDA IPC,--diffusion-debug-modeon, eval on the 1018-prompt test split every 20 rollouts, 200 rollouts.docs/models/h3/h3-image.md: the model page. Family config, launch, what to watch, recipe notes, reference results.A row for the model in
docs/index.mdandREADME.md, and the recipe under V indocs/user-guide/recipe-verification.md.miles/backends/fsdp_utils/actor.py(shared): a--debug-rollout-onlyrun skips the checkpoint save. The last rollout always saves and such an actor has loaded no model, so the frozen-weights control the page documents ran its rollouts and then failed insave_model.docs/user-guide/rewards.md: the recipe under the OCR subset and among the OCR reward's users.Why these settings
The step count, the flow shift and the guidance are fixed by the release (6-step distilled, one output head per step, CFG distilled in). Everything the recipe does choose comes from a measurement on 8 H200; the model page has the tables.
[A7]cpsat 0.8, not flow-sdecpsat 0.8 costs none on any window (sgl-project/sglang#51113)eval/ocr_testis 0.621 at 1e-4 and 0.550 at 2e-4, from 0.600--sglang-lora-merge-mode dynamic)train/model_output_mean_abs_diffgoes from 0.021 on rollout 0 to 0.030 on rollout 24; it stays at 0.020 withdynamic. A sync takes 1.2 s instead of 11.5 s, a rollout 14 s instead of 8 scpsadds no noise. On 8 fixed prompts the reward rose twice as fast as with a 2-step window. That measures fitting, not generalization; the two windows were not compared on unseen promptsThe learning rate is the setting that was first chosen wrong, and the page says how to avoid that. On 8 fixed prompts lr 2e-4 raises the reward 1.5 times as fast as 1e-4. On the full dataset the same 2e-4 makes the policy worse on every prompt it has not trained on. Two readings separate the cases:
eval/ocr_testis sampled without noise on fixed prompts, so two evals differ only by the weights.--rollout-seedand the unshuffled prompt order give rollout k the same prompts and noise in every run;--deterministic-modereaches only the trainer and makes the trained run itself repeatable. A run'srollout/reward/raw_meanminus that of a--debug-rollout-onlyrun is therefore its gain on unseen prompts, with the prompt-to-prompt spread (0.46 to 0.84 per rollout) cancelled. Rollout 0 differs by exactly 0.Validation
On this box, 8 H200, CI-recipe environment with diffusers 0.43.0 and numpy 1.26.4, sglang at sgl-project/sglang#51113 (b5e82c7ea), weights
MiniMaxAI/MiniMax-H3-Imageat 8ced6006.One run of the recipe's settings, 1000 rollouts in 22 hours. The recipe stops at 200 (25,600 images, 4.4 hours);
train/lris 1e-4 on every optimizer step, so the recipe's run is the first 200 rollouts of this one.The second row is the detail left in the 8 eval images wandb logs, always for the same 8 prompts: the mean luminance step between neighbouring pixels.
eval/ocr_test--diffusion-kl-betais 0, so nothing in the objective keeps the scene.save_model(fixed here; its metrics were complete): +0.013 +- 0.007 over rollouts 10-19, +0.032 +- 0.006 over 30-39, +0.042 +- 0.006 over 50-59.train/model_output_mean_abs_diffon a rollout's first optimizer step is 0.021 and 0.023 over the recipe's 200 rollouts (100-rollout means; 20-rollout means reach 0.025) and falls to 0.010 by 1000, as the scene fades.train/clipfracon the second optimizer step stays below 0.32 (20-rollout means).--num-rolloutand two flags the recipe no longer passes because they change nothing:--diffusion-eval-num-steps 6(the fallback to--diffusion-num-steps) and--diffusion-log-prob-no-const(forced on for cps).pre-commit runon the changed files is clean.tests/ci/run_suite.py --hw cpu --suite stage-a-cpuat this head (d587966): 688 passed.Not run:
save_modelguard, nor with the page's command, which no longer passes the--save-interval 100000that kept its periodic saves from the same crash. The guard is one early return, the same on every rank.transformer_diffusers/, andsglang-milesdoes not have [Feat] diffusion: [sglang-miles] Serve MiniMax-H3-Image training rollouts (cherry-pick #49552, #49574) sgl-project/sglang#51113.--diffusion-kl-beta, 0.04 in the SD3.5 OCR recipe) or a second reward such as PickScore. A run with KL 0.04 and PickScore as a zero-weight monitor had not finished when this was written.Open
save_modelguard fixes a crash that is onmainfor any--debug-rollout-onlyrun that reaches a save. It sits here because the page's control needs it; it could go tomainfirst as a one-commit PR.Not in this PR
--diffusion-kl-beta, a--clip-gradnear 1e-2.