Skip to content

Enhance DWG/DXF analyzer with column-wall-beam-slab detail reporting#1

Open
smitelagwar wants to merge 1 commit intomasterfrom
codex/write-dwg-analysis-tool-in-python
Open

Enhance DWG/DXF analyzer with column-wall-beam-slab detail reporting#1
smitelagwar wants to merge 1 commit intomasterfrom
codex/write-dwg-analysis-tool-in-python

Conversation

@smitelagwar
Copy link
Copy Markdown
Owner

Summary

  • classify INSERT blocks by structural naming prefixes to detect columns, walls, beams, and slabs
  • add per-element tabular output including element name, layer, coordinates, width, height, and area
  • include slab extraction from both slab-named blocks and slab-named closed polylines with dimensions
  • compute and report nearby pair distances for columns and beams (optionally filtered by --yakinlik-esigi)
  • keep axis spacing analysis and add richer full report formatting sections

CLI

  • new option: --yakinlik-esigi <float> to report only close column/beam pairs within threshold distance

Codex Task

Copy link
Copy Markdown

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

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: c9d6e05cff

ℹ️ 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 +216 to +217
points = [(x, y) for x, y, *_ in polyline.get_points()]
except Exception: # noqa: BLE001
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 Parse POLYLINE vertices when extracting slab polygons

_extract_slab_polygons explicitly queries both LWPOLYLINE and POLYLINE, but _polyline_to_polygon only reads coordinates via polyline.get_points(). For classic POLYLINE entities this call fails, is swallowed by the broad except, and returns None, so closed slab contours stored as POLYLINE are silently skipped and their area/count are missing from the report.

Useful? React with 👍 / 👎.

COLUMN_PREFIXES = ("SB", "SZ", "S")
WALL_PREFIXES = ("PB", "PZ", "P")
BEAM_PREFIXES = ("KB", "KR", "K", "KIRIS", "BEAM")
SLAB_PREFIXES = ("D",)
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 Tighten slab prefix matching to avoid false slab detection

Using SLAB_PREFIXES = ("D",) with startswith makes any block/layer name beginning with D classify as a slab, which can incorrectly pull in unrelated entities (for example common CAD names like DEFPOINTS/DOOR*) and inflate slab counts and total slab area; this impacts report accuracy whenever naming is not strictly constrained to slab-only D* identifiers.

Useful? React with 👍 / 👎.

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant