Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Compare Qwen3.5 GPU test against the real official checkpoint#723

Open
mnoukhov wants to merge 2 commits into
mainallenai/OLMo-core:mainfrom
qwen35-hf-test-cacheallenai/OLMo-core:qwen35-hf-test-cacheCopy head branch name to clipboard
Open

Compare Qwen3.5 GPU test against the real official checkpoint#723
mnoukhov wants to merge 2 commits into
mainallenai/OLMo-core:mainfrom
qwen35-hf-test-cacheallenai/OLMo-core:qwen35-hf-test-cacheCopy head branch name to clipboard

Conversation

@mnoukhov

@mnoukhov mnoukhov commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

The Qwen3.5 GPU comparison test previously built a synthetic random-weight Qwen3_5TextConfig. This restores a real-checkpoint comparison: it loads the official Qwen/Qwen3.5-0.8B weights and tokenizer and compares logits on a real prompt.

The test just calls from_pretrained("Qwen/Qwen3.5-0.8B") as-is (skipping if the checkpoint can't be obtained). To keep the GPU job from downloading the gated checkpoint in-job (which can exceed the 10-minute task timeout), the gantry run mounts Weka (oe-training-default) and points HF_HOME at a checkpoint cache there, so the weights are read from the local mount.

Required data (already done) populate the cache once from a Weka-mounted machine (with HF_TOKEN):

HF_HOME=/weka/oe-training-default/test-fixtures/hf hf download Qwen/Qwen3.5-0.8B

🤖 Generated with Claude Code

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Credits must be used to enable repository wide code reviews.

@mnoukhov
mnoukhov force-pushed the qwen35-hf-test-cache branch 2 times, most recently from 67b849a to 6304ba9 Compare June 12, 2026 22:13

@AkshitaB AkshitaB left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @mnoukhov ! For this particular test, is it better to just have a smaller test config rather than load the hf model?

@mnoukhov

mnoukhov commented Jun 15, 2026

Copy link
Copy Markdown
Contributor Author

I'm seeing this qwen 3.5 test as GPU version of test_logprobs_match_after_roundtrip which is CPU only. This feels more realistic since we're usually checking those logprobs on GPU

So I think it makes sense to do the GPU test with a real model instead of a tiny test config model

@mnoukhov
mnoukhov force-pushed the qwen35-hf-test-cache branch from 6304ba9 to 267b7f9 Compare June 17, 2026 19:44
@mnoukhov mnoukhov changed the title Predownload Qwen3.5 checkpoint into Beaker dataset to avoid GPU test timeouts Compare Qwen3.5 GPU test against the real official checkpoint Jun 17, 2026
@mnoukhov
mnoukhov force-pushed the qwen35-hf-test-cache branch from 267b7f9 to 15b88e4 Compare June 17, 2026 19:57
The Qwen3.5 GPU comparison test previously built a synthetic random-weight
Qwen3_5TextConfig. Restore a real-checkpoint comparison: load the official
Qwen/Qwen3.5-0.8B weights and tokenizer and compare logits on a real prompt.

To keep the GPU job from downloading the gated checkpoint in-job (which can
exceed the task timeout), the job mounts Weka and points HF_HOME at a checkpoint
cache there, so from_pretrained reads from the local mount. Local runs fall back
to a normal download, skipping the test if the checkpoint can't be obtained.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@mnoukhov
mnoukhov force-pushed the qwen35-hf-test-cache branch from 15b88e4 to b5dacd8 Compare June 17, 2026 20:05
@farhatkevin

Copy link
Copy Markdown
Contributor

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: e331cc5681

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

--env 'GOOGLE_APPLICATION_CREDENTIALS=/.google/credentials.json' \
--env 'TOKENIZERS_PARALLELISM=false' \
--env 'CUBLAS_WORKSPACE_CONFIG=:16:8' \
--env 'HF_HOME=/weka/oe-training-default/test-fixtures/hf' \

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Force cache-only loading in GPU CI

When this job runs with HF_HOME pointed at the Weka cache, from_pretrained() is still allowed to contact the Hub and download any missing or newer snapshot files. In the CI scenario this change is trying to protect (--task-timeout 10m and a ~GB Qwen checkpoint), a cache miss or model update can spend the whole Gantry task downloading instead of failing/skipping quickly. Set the Beaker task offline here (for example HF_HUB_OFFLINE=1) or pass local_files_only=True when using the Weka cache so the test only reads the mounted checkpoint in CI while local runs can still download normally.

Useful? React with 👍 / 👎.

@mnoukhov
mnoukhov force-pushed the qwen35-hf-test-cache branch from e331cc5 to de645e0 Compare June 18, 2026 20:59

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: de645e0b7c

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines +68 to 72
hf_model = _load_pretrained(
transformers.Qwen3_5ForCausalLM,
torch_dtype=torch.float32,
attn_implementation="eager",
)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Load the text-only Qwen3.5 weights

When this runs against the official Qwen/Qwen3.5-0.8B cache, the repo is a multimodal checkpoint: its text weights are stored under model.language_model.*, while the concrete Qwen3_5ForCausalLM class instantiates a text-only model whose keys are model.*. Loading this class directly from the multimodal repo therefore either gets turned into a skip by _load_pretrained or leaves the text model initialized without the official weights, so the new CI comparison no longer validates the real checkpoint. Use the auto text-only path or explicitly load/remap the text_config/model.language_model weights before comparing.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.