fix: skip truncation for endpoints submissions in truncate_accuracy_log.py#2631
Merged
pgmpablo157321 merged 1 commit intoJul 15, 2026
Conversation
…tale results.json The endpoints accuracy artifact was renamed from results.json (with a responses field) to accuracy/accuracy_results.json in mlcommons/endpoints#400, which also dropped the responses field entirely (per-sample text now lives in events.jsonl, not part of the submission). truncate_accuracy_log.py still looked for the old results.json/responses shape and would only log "missing" for every endpoints submission. Detect the endpoints layout via the scenario-root config.yaml and skip truncation, and remove the now-dead PERFORMANCE_ENDPOINTS_DIR/ACCURACY_ENDPOINTS_DIR constants left over from the loader.py refactor to ENDPOINTS_SCENARIO_DIR. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Contributor
|
MLCommons CLA bot All contributors have signed the MLCommons CLA ✍️ ✅ |
pgmpablo157321
approved these changes
Jul 15, 2026
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
_truncate_endpoints_resultsintruncate_accuracy_log.pytargetedaccuracy/results.json'sresponsesfield, which no longer exists: mlcommons/endpoints#400 renamed the artifact toaccuracy/accuracy_results.jsonand droppedresponsesentirely (per-sample response text now lives inevents.jsonl, which isn't part of the MLPerf submission persubmission_structure.md). As a result this codepath currently only ever logs"... missing"for every endpoints submission._is_endpoints_submission(), which detects the endpoints layout via the scenario-rootconfig.yaml/config.yml(same markerendpoints_parser.pyuses) and skips truncation cleanly — there's nothing left inaccuracy_results.jsonthat needs shrinking.PERFORMANCE_ENDPOINTS_DIR/ACCURACY_ENDPOINTS_DIRinconstants.py— dead since theloader.pyrefactor ontoENDPOINTS_SCENARIO_DIRin this sameupdate_endpoints_structurebranch; no remaining references anywhere in the repo.Test plan
python3 -m py_compileon both changed filessubmission_checker.main/loader/constantsstill import cleanly after removing the two dead dicts (wildcard-imported, so a stray reference wouldNameErrorat import time)config.yaml+performance/run_1/results_summary.json+accuracy/accuracy_results.json) and rantruncate_accuracy_log.pyagainst it — logs the skip message, leavesaccuracy_results.jsonbyte-for-byte unchanged, creates no backup files🤖 Generated with Claude Code