Dimension
The Dimension model captures a single dimensional annotation extracted from a drawing. It preserves the measured value, units, and tolerance scheme, along with the label as it appears on the drawing, the number of instances the callout applies to, and a confidence score. Through the tolerance details it records whether the dimension is theoretically exact, a reference value, or covered by a general tolerance. This normalized representation lets you run tolerance stack-ups, generate inspection plans, or compare revisions to see how sizing has changed without reinterpreting each drawing manually.
Words written next to a dimension can change what it means without changing its value. Dimension returns them as boolean flags, all false unless the drawing writes the qualifier:
| Flag | Written as, for example | Meaning |
|---|---|---|
is_pitch_circle_diameter | PCD 80, LK Ø 120, TK Ø 122 | The diameter of the circle on which the centres of a pattern of holes lie (bolt circle), or a gear's pitch circle. size is that circle's diameter, not a hole's. |
is_typical | Ø10 TYP | The dimension applies to every like feature of the part. quantity stays the count written on the drawing. |
is_internal | Ø40 INT, Ø40 innen | The dimension measures an inner feature, such as a bore or an inside contour. |
is_external | Ø30 EXT, Ø30 außen | The dimension measures an outer feature, such as a shaft or an outside contour. |
is_circulating | 2 ALL AROUND, 2 umlaufend | The dimension holds all the way around the closed contour or circumference. |
The label still spells the qualifier out (Ø120 PITCH CIRCLE DIAMETER), so code that reads the label keeps working. Most drawings leave internal and external to the view, so false on one of them does not imply the other.
Bases: Feature
Represents a measurement cue in an engineering or technical drawing.
| PARAMETER | DESCRIPTION |
|---|---|
reference_id | Reference ID to identify the object. TYPE: |
label | A short description of the feature in a human-readable format. TYPE: |
confidence | Confidence in the feature extraction or interpretation. TYPE: |
quantity | The quantity or value associated with the measurement, must be non-negative. TYPE: |
size | Details about the size, including type, nominal value, tolerance, and unit. TYPE: |