Skip to content

feat(evaluation): add core result inspection plan - #4

Open
yujeongdev wants to merge 2 commits into
mainfrom
evaluation-plan
Open

feat(evaluation): add core result inspection plan#4
yujeongdev wants to merge 2 commits into
mainfrom
evaluation-plan

Conversation

@yujeongdev

Copy link
Copy Markdown
Owner

Summary

  • add PLAN.md with the proposed evaluation PR sequence
  • add scripts/inspect_pipeline_result.py for core result inspection
  • inspect required files, basic_info.json, coordinate text, voxel arrays, OBJ parts, GLB load, and optional MuJoCo XML load
  • write inspection_summary.json and inspection_report.md into result directories

Verification

  • conda run -n physx-decoder python -m py_compile scripts/inspect_pipeline_result.py
  • conda run -n physx-decoder python scripts/inspect_pipeline_result.py --help
  • local scissors result inspected as PASS_WITH_WARNINGS
  • local microwave result inspected as PASS_WITH_WARNINGS

Notes

  • MuJoCo XML load check is optional and reports skipped_missing_package when mujoco is not installed.
  • Runtime reports are generated under ignored pipeline_runs/ directories and are not committed.

Add the evaluation automation roadmap and a core result inspector that writes JSON and Markdown summaries for generated PhysX-Anything outputs. This establishes the report schema needed by topology checks, human review pages, render previews, and optional VLM evaluation.

Constraint: Evaluation work should start with deterministic local checks before adding VLM-as-judge or browser UI layers.
Rejected: Implement HTML review first | it needs a stable inspection summary schema to display.
Rejected: Commit runtime pipeline outputs | reports are generated from ignored pipeline_runs directories.
Confidence: high
Scope-risk: narrow
Directive: Keep later evaluation checks appending to inspection_summary.json rather than inventing parallel result formats.
Tested: conda run -n physx-decoder python -m py_compile scripts/inspect_pipeline_result.py; conda run -n physx-decoder python scripts/inspect_pipeline_result.py --help; ran inspector on local scissors and microwave results, both producing PASS_WITH_WARNINGS without hard errors.
Not-tested: MuJoCo load check because mujoco is not installed in the decoder environment.

@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: cb924563af

ℹ️ 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".

Comment thread scripts/inspect_pipeline_result.py Outdated

allind = result_dir / "allind.npy"
if allind.exists():
arr = np.load(allind)

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Handle unreadable allind.npy without aborting inspection

check_voxel_arrays wraps np.load for each ind_*.npy, but allind.npy is loaded without a guard. If allind.npy is truncated/corrupt (a common failure mode for interrupted runs), np.load raises here and the script exits before inspection_summary.json / inspection_report.md are written, which defeats the purpose of diagnosing failed outputs. Please catch this exception and record it in report["errors"] like the per-part loads.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

Fixed in 05381cd (05381cde3687bbf084a947454d20374888d698ae).

What changed:

  • Wrapped np.load(allind.npy) in try/except, matching the per-part ind_*.npy handling.
  • Corrupt/truncated allind.npy is now recorded in report["errors"] as failed to load allind.npy: ... instead of aborting the inspector before reports are written.

Verification:

  • conda run -n physx-decoder python -m py_compile scripts/inspect_pipeline_result.py
  • Focused temp-dir test creates an invalid allind.npy and confirms the inspector records a report error rather than raising.

Comment on lines +104 to +107
if "-" in token:
a, b = map(int, token.split("-"))
if a > b:
descending.append(token)

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 Validate coord token bounds against 0-32767 range

The coordinate-text check currently validates token syntax and descending ranges, but it never enforces numeric bounds, so tokens like 50000 or 10-60000 are accepted without warning. In this pipeline, coord tokens are expected to represent 32^3 voxel indices; out-of-range values are later clipped during decoding, so this omission hides malformed generation output that the inspector is supposed to surface.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

Fixed in 05381cd (05381cde3687bbf084a947454d20374888d698ae).

What changed:

  • Added MAX_VOXEL_INDEX = 32 ** 3 - 1 and bounds validation for both single coordinate tokens and range tokens in coord_*.txt.
  • Tokens like 50000 or 10-60000 are now surfaced as warnings: has out-of-range voxel tokens, so malformed VLM output is visible before downstream clipping can hide it.

Verification:

  • Focused temp-dir test with coord_0.txt containing 10 10-60000 50000 confirms the out-of-range warning is emitted.

Keep inspection reports diagnostic even when allind.npy is unreadable and surface out-of-range coordinate text tokens before downstream clipping hides malformed VLM output.

Constraint: Inspection must diagnose interrupted or malformed runs instead of aborting before report generation.
Rejected: Let np.load(allind.npy) raise | that prevents inspection_summary.json and inspection_report.md from being written for broken outputs.
Confidence: high
Scope-risk: narrow
Directive: Treat generated text and array load failures as report errors rather than unhandled inspector exceptions.
Tested: conda run -n physx-decoder python -m py_compile scripts/inspect_pipeline_result.py; focused temp-dir test detects out-of-range coord tokens and records corrupt allind.npy as an error.
Not-tested: Full inspection rerun on every historical pipeline_runs directory after this focused fix.

Copy link
Copy Markdown
Owner Author

@codex review

Review requested after addressing the inspector robustness feedback:

  • corrupt/truncated allind.npy is now recorded as a report error instead of aborting inspection
  • out-of-range coord_*.txt voxel tokens are now surfaced as warnings

@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: 05381cdba9

ℹ️ 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".

Comment on lines +151 to +152
allind = result_dir / "allind.npy"
if allind.exists():

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 Report missing allind.npy when voxel summary is absent

check_voxel_arrays only enters the allind.npy branch when the file exists, so a result directory with allind.npy deleted (or never produced) records no error/warning and can still end up as PASS/PASS_WITH_WARNINGS. Because this artifact is part of the core voxel outputs inspected by this script, silently skipping its absence hides a broken/incomplete run and can let downstream evaluation proceed on incomplete data.

Useful? React with 👍 / 👎.

Comment on lines +158 to +162
report["allind"] = {"shape": list(arr.shape), "voxels": int(arr.shape[0]) if arr.ndim else 0}
if arr.ndim != 2 or arr.shape[1] != 3:
add_error(report, f"allind.npy has invalid shape: {arr.shape}")
elif total_ind_voxels and arr.shape[0] != total_ind_voxels:
add_warning(report, f"allind voxel count {arr.shape[0]} differs from sum(ind_*.npy) {total_ind_voxels}")

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 Validate allind.npy coordinate bounds before passing inspection

After loading allind.npy, the code checks only shape and voxel-count consistency, but never verifies that coordinates stay within [0, 31] (or reports min/max like ind_*.npy). A corrupted allind.npy with valid shape/count but out-of-range values will therefore pass this check, which weakens the inspector’s ability to catch invalid voxel data.

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.

1 participant