fix(tests): repair the joint_cross_attn real-Cosmos GPU test - #16
Merged
Conversation
test_joint_cross_attn_forward_on_real_cosmos has not run since the config rename in 4d8df56, which replaced configs/model/video_backbone/cosmos_predict25.yaml with cosmos_predict25_2b.yaml. The override was missed, so Hydra raised MissingConfigException before any model code ran. It is the only stale reference left -- the usage docs and the openwam-serve --help text already use the new name. The failure is invisible unless the Cosmos-Predict2.5-2B checkpoint is mounted, so CI skips it and it surfaced only on a box that had the weights. With the config resolving, the test then hit FileNotFoundError from the live Reason1 text encoder: it was the one real-Cosmos GPU test not requesting the stub_reason1 fixture, which exists so these tests skip the 16 GB Qwen load. Its closest sibling, test_tri_system_forward_on_real_cosmos, uses it. The test never needed the encoder anyway -- it passes `context` to forward() directly. Verified against real Cosmos-Predict2.5-2B weights on an H200: the file now runs 5 passed, and the GPU case genuinely exercises the DiT rather than skipping. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
xueminchi
self-requested a review
September 8, 2026 17:07
xueminchi
approved these changes
Sep 8, 2026
xueminchi
left a comment
Collaborator
There was a problem hiding this comment.
Reviewed the two-line test repair and the related config, fixture, and model-loading/forward paths. The Hydra override matches the current cosmos_predict25_2b config. Reusing stub_reason1 is appropriate here: context is supplied directly to forward, and the fixture replaces only the text encoder, leaving the real Cosmos DiT load and the existing assertions intact. No blocking issues found. CI lint and tests passed; I did not independently rerun the checkpoint-backed GPU test.
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.
test_joint_cross_attn_forward_on_real_cosmoshas not actually run since commit4d8df56("Document OpenWAM usage and unify component keys"), which replacedconfigs/model/video_backbone/cosmos_predict25.yamlwithcosmos_predict25_2b.yaml. The test's Hydra override was missed, so it raisedMissingConfigExceptionbefore any model code ran:It is the only stale reference left —
assets/openwam_usage_docs/train-and-deploy.mdand theopenwam-serve --helptext already usecosmos_predict25_2b, andmodel_loader.pygates on thecosmos_predict25_prefix.The failure is invisible without the Cosmos-Predict2.5-2B checkpoint mounted, so CI skips it and it only surfaces on a box that has the weights — which is how it went unnoticed.
Two lines
1. The config name.
model/video_backbone=cosmos_predict25→cosmos_predict25_2b.2. The
stub_reason1fixture. With Hydra resolving, the test then hitFileNotFoundErrorfrom the live Reason1 text encoder, against the config's/path/to/Cosmos-Reason1-7Bplaceholder. This was the one real-Cosmos GPU test not requestingstub_reason1, the fixture that exists precisely so these tests skip the 16 GB Qwen load — its closest siblingtest_tri_system_forward_on_real_cosmosuses it. The test never needed a real encoder anyway: it passescontexttoforward()directly.Verification
Run against real Cosmos-Predict2.5-2B weights on an H200 (
OPENWAM_COSMOS25_2Bpointed at the checkpoint):The GPU case now genuinely loads the DiT and exercises the forward, rather than erroring or skipping. Full suite with the checkpoint visible:
versus
1 failed, ... 20 skippedbefore — the 8 fewer skips are the Cosmos GPU tests the checkpoint unlocks.ruff checkandruff format --checkclean.🤖 Generated with Claude Code