Repository navigation
Add MMMU-Pro image-QA benchmark (Molmo2-4B) - #232
Merged
Merged
Conversation
A single `mmmu_pro` task evaluates the released HF Molmo2-4B on all three official MMMU-Pro settings (standard 10-option, standard 4-option, vision) and emits one metrics.json with standard_10_accuracy, standard_4_accuracy, vision_accuracy and the primary `overall` = (standard-10 + vision)/2 (the SOTA-reported number). Decoupled from the existing `mmmu` task — its own prompts/parser/scorer, faithful to the official MMMU-Benchmark/MMMU mmmu-pro repo: - common/image_qa/mmmu_pro.py: verbatim direct prompts; replace_images_tokens (interleaved images attached in <image i> token-appearance order, not key order, since options are shuffled); official raw-response answer parser (rfind "Answer:" then (A)/"A "/"A."/option-text), MC-only, seeded fallback. - common/scorers/mmmu_pro.py: MmmuProScorer (raw response, no clean_prediction). - evals/tasks/mmmu_pro.py: the task (3 settings interleaved), per-setting + overall metrics, multi/single-image format_request. - evals/suites/molmo2.py: "mmmu_pro" added to MOLMO2_IMAGE_QA_TASKS (its overall counts as one 0-1 entry, like the other image-QA benchmarks). - tests/evals/tasks/test_mmmu_pro.py: parser ladder, image-order, prompts, metrics, request (CPU-only). Verified: full suite 1773 passed; full Molmo2-4B run (5190 ex) overall 26.01% (standard-10 35.20 / standard-4 44.62 / vision 16.82). Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_017rWjjwFXMM556pd4ixrQ96
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.
Summary
Adds MMMU-Pro (
MMMU/MMMU_Pro) — the harder, more-robust successor to MMMU — as a newimage-QA benchmark for the released HF
allenai/Molmo2-4B, evaluated through the sameHuggingFaceProvidermultimodal path (presetmolmo2-4b).A single
mmmu_protask runs all three official settings and produces onemetrics.jsonwith
standard_10_accuracy,standard_4_accuracy,vision_accuracy, and the primaryoverall= (standard-10 + vision) / 2 — the number SOTA models report.It is decoupled from the existing
mmmutask (its own prompts, parser, and scorer; no reuse ofmmmu_parsing.py/MmmuScorer/format_mc_question), faithful to the officialMMMU-Benchmark/MMMUmmmu-prorepo, and is added to themolmo2_imageqasuite (itsoverallcounts as one 0-1 entry, like the other image-QA benchmarks).
Verified — Molmo2-4B (fp32 + bf16 autocast, full run, 5190 examples)
Faithful to the official MMMU-Pro protocol
prompts.yaml(CoT mode not used): standard ="Answer with the option letter from the given choices directly."; vision = the same +" The last line of your response should be of the following format: 'Answer: $LETTER' …".question + "A. …\nB. …" + direct prompt(A–J for 10 options) with allinterleaved images attached in
<image i>token-appearance order — options are shuffled, sotoken order need not match
image_ikey order (officialreplace_images_tokens,<image i>→<image>). Vision sends only the instruction + the single screenshot (imagecolumn); thequestion/options are rendered inside the screenshot.
Answer:marker →(A)→"A "→"A."→ option text; multiple → last occurrence; per-example seeded fallback for re-run determinism.
Changes
src/olmo_eval/common/image_qa/mmmu_pro.py(new) — prompts, prompt assembly,replace_images_tokens, and the officialparse_multi_choice_response/mmmu_pro_score.src/olmo_eval/common/scorers/mmmu_pro.py(new) —MmmuProScorer(raw response, noclean_prediction).src/olmo_eval/evals/tasks/mmmu_pro.py(new) — the singlemmmu_protask (3 settings,interleaved), per-setting +
overallmetrics, and aformat_requestthat attaches themulti-image (standard) or single-screenshot (vision) tuple.
src/olmo_eval/evals/suites/molmo2.py—"mmmu_pro"added toMOLMO2_IMAGE_QA_TASKS.tests/evals/tasks/test_mmmu_pro.py(new) — CPU-only: parser ladder, shuffled image-order,prompts, per-setting + overall metrics, request construction.
No new dependencies (pure HF hub;
MMMU/MMMU_Procached likeMMMU/MMMU).Verification
ruff check/ruff format --checkclean;ty checkclean on the new files; full suite1773 passed, 5 skipped. Full GPU run completed and produced the numbers above.