Skip to content

feat(evaluation): detect part topology inconsistencies - #5

Open
yujeongdev wants to merge 1 commit into
evaluation-planfrom
topology-inspection
Open

feat(evaluation): detect part topology inconsistencies#5
yujeongdev wants to merge 1 commit into
evaluation-planfrom
topology-inspection

Conversation

@yujeongdev

Copy link
Copy Markdown
Owner

Summary

  • extend inspect_pipeline_result.py with part topology diagnostics
  • compute projected hole counts for OBJ parts across XY/XZ/YZ views
  • attach semantic part names from basic_info.json
  • warn when repeated semantic parts have inconsistent projected hole counts
  • preserve microwave-style solid handles by avoiding a blanket handle-must-have-hole rule

Verification

  • conda run -n physx-decoder python -m py_compile scripts/inspect_pipeline_result.py
  • local scissors result now reports repeated Blade Handle Set projected-hole mismatch
  • local microwave result remains PASS_WITH_WARNINGS without a false handle-hole warning

Notes

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

ℹ️ 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
Comment on lines +189 to +193
try:
from scipy import ndimage
from skimage.draw import polygon
except Exception:
return -1

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 Warn when projected-hole checks are skipped

If scipy or skimage is unavailable, mesh_projected_holes returns -1 silently, and callers treat that as a normal numeric result. In environments where trimesh is installed but those optional deps are not, the new topology diagnostics are effectively disabled without any warning, so reports can look healthy while the projected-hole consistency checks never ran.

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 bcbdfae (bcbdfaed7f69e8cb85bc9946da7aef1cceec8549).

What changed:

  • mesh_projected_holes() no longer silently returns -1 when scipy/skimage imports fail.
  • check_part_topology() catches the missing dependency once, emits a warning (projected-hole topology checks skipped; missing dependency: ...), and records None for projected-hole counts instead of treating a sentinel as normal data.

Verification:

  • conda run -n physx-decoder python -m py_compile scripts/inspect_pipeline_result.py
  • Local scissors inspection still reports the repeated Blade Handle Set projected-hole mismatch.
  • Monkeypatched import test verifies missing scipy/skimage emits the skipped-check warning.

Extend result inspection with projected hole counts, semantic part names, and repeated-part consistency checks. This catches cases like scissors where one blade-handle counterpart preserves an opening while the other is filled, and it reports when optional projected-hole dependencies are unavailable.

Constraint: Mesh quality issues need deterministic local warnings before adding human review or VLM judging.
Rejected: Treat every handle name as requiring a hole | microwave handles are solid protrusions, so repeated-part inconsistency is a better first signal.
Rejected: Silently return sentinel values when scipy/skimage are missing | skipped topology checks must be visible in the report.
Confidence: high
Scope-risk: narrow
Directive: Keep topology warnings advisory and avoid hard failures unless meshes are empty or unreadable.
Tested: conda run -n physx-decoder python -m py_compile scripts/inspect_pipeline_result.py; inspected local scissors result and got repeated Blade Handle Set projected-hole mismatch warning; inspected local microwave result without false handle-hole warning; monkeypatched import test verifies missing scipy/skimage emits a projected-hole skipped warning.
Not-tested: Robustness across arbitrary camera orientations and non-manifold meshes.
@yujeongdev
yujeongdev force-pushed the topology-inspection branch from 3392753 to bcbdfae Compare April 15, 2026 19:24

Copy link
Copy Markdown
Owner Author

@codex review

Review requested after addressing topology dependency feedback:

  • projected-hole checks now warn when optional scipy/skimage dependencies are unavailable instead of silently returning sentinel values

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

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

mapping = {}
for part in basic_info.get("parts", []):
if isinstance(part, dict) and "label" in part:
mapping[str(part.get("label"))] = str(part.get("name", ""))

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 Preserve null part names when building label map

Converting part.get("name", "") with str(...) turns JSON null names into the literal string 'None', so unnamed parts are treated as a real semantic name and can be grouped as repeated 'none' parts, producing misleading topology inconsistency warnings. This is triggered whenever basic_info.json includes "name": null; using an empty-string fallback like part.get("name") or "" avoids false positives.

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