Source: https://gometry.monicz.dev/api/results/

# Result types

Named result values and aligned feature records returned by multi-output operations.

**Related:** [Constructive operations](https://gometry.monicz.dev/guide/constructive/)

## Circle

A solved circle with a source-CRS center and a radius in `unit`.

`working_crs` identifies the coordinate frame in which the disk is solved.
Geographic metric results with one or two distinct point sites retain an
ellipsoidal solution; other geographic circles use a local projection.
`to_polygon` realizes the retained disk without repeating its optimization;
polygon resolution does not change its center or radius.

### center `property`

```python
center: Point
```

Circle center in the input CRS, retaining its coordinate epoch.
Computed centers are XY; selected zero-radius source points retain Z/M.

Returns:

| Type | Description |
| --- | --- |
| `Point` | Center in the source CRS and epoch. Empty circles return POINT EMPTY. |

### is\_empty `property`

```python
is_empty: bool
```

Whether the circle has no points. A zero-radius circle is not empty.

Returns:

| Type | Description |
| --- | --- |
| `bool` | True for an empty circle; false for a solved disk or source point. |

### radius `property`

```python
radius: float
```

Radius in the selected metric units; NaN for an empty circle.

Returns:

| Type | Description |
| --- | --- |
| `float` | Radius in the selected units; NaN for an empty circle. |

### unit `property`

```python
unit: Literal['meters', 'planar']
```

`meters` for SI radii, or `planar` for native coordinate units.

Returns:

| Type | Description |
| --- | --- |
| `str` | Effective radius units. |

### working\_crs `property`

```python
working_crs: str | None
```

Working CRS, or None when no CRS-based working frame is used.

Returns:

| Type | Description |
| --- | --- |
| `str or None` | Working CRS, or None when no CRS-based working frame is used. |

### to\_polygon

```python
to_polygon(*, quadrant_segments: int = 16) -> Polygon | Point
```

Realize the retained disk as a polygon, or a Point for a degenerate disk.

In a Cartesian working frame, inscribed polygons lie inside their
certified disk and bounding polygons enclose their exact disk.
Ellipsoidal one-/two-point disks use the same local-projection
approximation as geographic Point.buffer. Geographic output is in the source CRS.
Empty circles return POLYGON EMPTY. Finite numeric solutions can exist
even when polygon coordinates cannot be represented, in which case this
method raises OverflowError without invalidating the numerical solution.

Parameters:

| Name | Type | Description | Default |
| --- | --- | --- | --- |
| `quadrant_segments` | `int` | Positive number of straight segments per quarter-circle. | `16` |

Returns:

| Type | Description |
| --- | --- |
| `Polygon or Point` | Polygonal realization in the source CRS and epoch; a Point for a degenerate disk and POLYGON EMPTY for an empty disk. |

Raises:

| Type | Description |
| --- | --- |
| `GeometryError` | If the segment count is not positive or cannot be represented. |
| `OverflowError` | If the certified polygon cannot be represented with finite coordinates. |
| `CRSError` | If a geographic polygon cannot fit the local projection's accuracy domain. Ellipsoidal center and radius remain available for widely separated sites. |

## CircleArray

An immutable sequence of solved circles with null-aware vector projections.

`center` returns a point GeometryArray; `radius` returns a read-only
NumPy array with NaN for empty or missing rows. `is_missing` distinguishes
missing rows from empty circles. Scalar indexing returns Circle or None;
slices, integer gathers, and boolean masks retain the circle solutions
without repeating their optimization.

### center `property` `readonly`

```python
center: GeometryArray[Point] | GeometryArray[Point | None]
```

Circle centers as a point GeometryArray in the source CRS and epoch.
Empty circles have empty Points; missing rows remain missing.

Returns:

| Type | Description |
| --- | --- |
| `GeometryArray of Point` | One center per row, in the source CRS and epoch. |

### is\_empty `property`

```python
is_empty: NDArray[bool_]
```

Read-only boolean mask identifying empty circles.

Returns:

| Type | Description |
| --- | --- |
| `numpy.ndarray of bool` | True for empty circles; false for nonempty and missing rows. |

### is\_missing `property`

```python
is_missing: NDArray[bool_]
```

Read-only boolean mask distinguishing missing rows from empty circles.

Returns:

| Type | Description |
| --- | --- |
| `numpy.ndarray of bool` | True for missing rows; false for present rows, including empty circles. |

### radius `property`

```python
radius: NDArray[float64]
```

Read-only float64 radii in each circle's selected units.
Empty and missing rows are NaN.

Returns:

| Type | Description |
| --- | --- |
| `numpy.ndarray of float` | Read-only radius per row; NaN for empty and missing rows. |

### unit `property`

```python
unit: list[Literal['meters', 'planar'] | None]
```

Effective radius units per row: meters or planar native coordinate units.
Missing rows are None.

Returns:

| Type | Description |
| --- | --- |
| `list of str or None` | Effective units per row. |

### working\_crs `property`

```python
working_crs: list[str | None]
```

Working CRS definitions per row, or None where absent.

Returns:

| Type | Description |
| --- | --- |
| `list of str or None` | Working CRS per row, or None where absent. |

### count

```python
count(value: object) -> int
```

Number of rows equal to a Circle, or missing rows when value is None.

Parameters:

| Name | Type | Description | Default |
| --- | --- | --- | --- |
| `value` | `Circle or None` | Circle value to count; None counts missing rows. | *required* |

Returns:

| Type | Description |
| --- | --- |
| `int` | Number of matching rows. |

### index

```python
index(value: object, start: SupportsIndex = 0, stop: SupportsIndex | None = None) -> int
```

First matching row within start:stop, with normal negative-index bounds.

Parameters:

| Name | Type | Description | Default |
| --- | --- | --- | --- |
| `value` | `Circle or None` | Circle value to find; None finds a missing row. | *required* |
| `start` | `int` | Start of the search window; negative indices count from the end. | `0` |
| `stop` | `int or None` | End of the search window; None searches through the end. | `None` |

Returns:

| Type | Description |
| --- | --- |
| `int` | Index of the first matching row. |

Raises:

| Type | Description |
| --- | --- |
| `ValueError` | If the selected window contains no equal Circle or missing row. |

### to\_polygon

Accepted call forms

```python
to_polygon(*, quadrant_segments: int = 16) -> GeometryArray[Polygon | Point]
```

```python
to_polygon(*, quadrant_segments: int = 16) -> GeometryArray[Polygon | Point | None]
```

Realize each retained disk without repeating its optimization.

Parameters:

| Name | Type | Description | Default |
| --- | --- | --- | --- |
| `quadrant_segments` | `int` | Positive number of straight segments per quarter-circle, shared by every row. Resolution does not change the solved centers or radii. | `16` |

Returns:

| Type | Description |
| --- | --- |
| `GeometryArray` | Polygon or degenerate Point per row, in the source CRS and epoch. Empty disks yield empty polygons; missing rows remain missing. |

Raises:

| Type | Description |
| --- | --- |
| `GeometryError` | If the segment count is not positive or cannot be represented. |
| `OverflowError` | If a certified polygon cannot be represented with finite coordinates. |
| `CRSError` | If a geographic realization exceeds the local-projection accuracy domain. |

## ValidationReport

A structured geometry-validity verdict.

Returned by `geom.validate()`: truthy when the geometry is valid;
otherwise `report.reason` names the OGC violation, `report.location`
pinpoints it, `report.path` addresses the offending part, and
`report.code`/`report.detail` provide stable machine-readable and
human-readable issue data.
Validation reports describe invalid geometries and their reasons.

### code `property`

```python
code: str | None
```

Stable machine-readable validity code, or `None` for a valid report.

Returns:

| Type | Description |
| --- | --- |
| `str or None` |  |

### detail `property`

```python
detail: str | None
```

Detail for the first validity issue, or `None` for a valid report.

Returns:

| Type | Description |
| --- | --- |
| `str or None` |  |

### location `property`

```python
location: tuple[float, float] | None
```

`(x, y)` location of the first problem, when known.

For quotient-topology issues, the location is a canonical coordinate of
the issue's contact set, chosen deterministically by minimum latitude
then longitude.

Returns:

| Type | Description |
| --- | --- |
| `tuple or None` |  |

### path `property`

```python
path: str | None
```

Structural path to the first problem (e.g. `'$.shell'`), when known.

Returns:

| Type | Description |
| --- | --- |
| `str or None` |  |

### reason `property`

```python
reason: str | None
```

Human-readable reason for the first validity problem, or `None`.

Returns:

| Type | Description |
| --- | --- |
| `str or None` |  |

### valid `property`

```python
valid: bool
```

Whether the geometry is valid (also the report's truth value).

Returns:

| Type | Description |
| --- | --- |
| `bool` |  |

### \_\_bool\_\_

```python
__bool__() -> bool
```

True if self else False

## Extremes

Accepted call forms

```python
Extremes(west: ExtremeT, south: ExtremeT, east: ExtremeT, north: ExtremeT) -> Extremes[ExtremeT]
```

The westmost/southmost/eastmost/northmost vertices of a geometry.

Returned by `Geometry.extremes()` (four scalar `Point` fields, or `None`
for an empty geometry) and `GeometryArray.extremes()` (four row-aligned
`GeometryArray[Point | None]` columns; missing rows remain missing and
present empty rows contain empty points). Unpacks as `(west, south, east,
north)`; ties keep the first vertex in storage order, and Z/M ordinates are
carried through.

### east `instance-attribute`

```python
east: ExtremeT
```

The vertex with the largest X.

### north `instance-attribute`

```python
north: ExtremeT
```

The vertex with the largest Y.

### south `instance-attribute`

```python
south: ExtremeT
```

The vertex with the smallest Y.

### west `instance-attribute`

```python
west: ExtremeT
```

The vertex with the smallest X.

## Features

Accepted call forms

```python
Features(geometries: GeometryArray[Geometry | None], properties: Mapping[str, Any] | Iterable[Mapping[str, Any] | None] | None = None, ids: Iterable[FeatureId] | None = None) -> Features
```

Aligned feature columns returned by `from_geojson(..., features=True)`.

Unpack as `geometries, properties, ids = features`. Each metadata entry
corresponds to the geometry at the same row; use `len(features.geometries)`
for the feature count. The outer columns are fixed, while property
dictionaries remain editable. `__geo_interface__` exposes the aligned
record as a GeoJSON FeatureCollection.

Build row-aligned feature columns.

Parameters:

| Name | Type | Description | Default |
| --- | --- | --- | --- |
| `geometries` | `GeometryArray[Geometry \| None]` | One geometry or `None` for each input feature. | *required* |
| `properties` | `Mapping[str, Any] \| Iterable[Mapping[str, Any] \| None] \| None` | A mapping or object with a callable `keys()` is broadcast as an independent shallow copy per row. An iterable supplies one mapping or `None` per geometry and is consumed once. `None` supplies one missing-properties value per geometry. | `None` |
| `ids` | `Iterable[FeatureId] \| None` | One string, non-boolean integer, finite float, or `None` per geometry. `None` supplies one missing id per geometry. | `None` |

Returns:

| Type | Description |
| --- | --- |
| `Features` | The geometry, property, and id columns aligned by input row. |

Raises:

| Type | Description |
| --- | --- |
| `TypeError` | If geometries is not a GeometryArray, a property input is not a mapping or row iterable, a property key is not a string, or an id is not a string, non-boolean integer, finite float, or `None`. |
| `GeometryError` | If property or id rows do not match the geometry count, property keys repeat, or a numeric id is not finite. |

### geometries `instance-attribute`

```python
geometries: GeometryArray[Geometry | None]
```

One parsed geometry or `None` per input feature.

### ids `instance-attribute`

```python
ids: tuple[FeatureId, ...]
```

Row-aligned string, non-boolean integer, finite float, or `None` ids.

An entry is `None` where the feature carried no id.

### properties `instance-attribute`

```python
properties: tuple[dict[str, Any] | None, ...]
```

Row-aligned property mappings; `None` means no properties were supplied.

A single input mapping is shallow-copied for each row, so editing one
returned dictionary does not change another row.

### \_\_iter\_\_

```python
__iter__() -> Iterator[GeometryArray[Geometry | None] | tuple[dict[str, Any] | None, ...] | tuple[FeatureId, ...]]
```

Unpack as `geometries, properties, ids` (three fields).

## PolygonizeResult

Accepted call forms

```python
PolygonizeResult(polygons: GeometryArray[Polygon], cut_edges: Groups[GeometryArray[LineString] | GroupMissingT_co], dangles: Groups[GeometryArray[LineString] | GroupMissingT_co], invalid_rings: Groups[GeometryArray[LineString] | GroupMissingT_co]) -> PolygonizeResult[GroupMissingT_co]
```

Full polygonization output: the polygons plus the leftover linework.

Returned by `polygonize_all(diagnostics=True)`; unpacks as `(polygons, cut_edges,
dangles, invalid_rings)`, or use the named fields. `polygons` is the
pooled result; each diagnostic is a `Groups` of `GeometryArray[LineString]`
rows, one per input source. Missing sources yield `None` rows, distinct
from present sources with no diagnostic linework. The generic argument is
`None` when source rows may be missing; it defaults to `Never` for dense
source rows.

### cut\_edges `instance-attribute`

```python
cut_edges: Groups[GeometryArray[LineString] | GroupMissingT_co]
```

Noded edges that are not part of a polygon, grouped by source row.

### dangles `instance-attribute`

```python
dangles: Groups[GeometryArray[LineString] | GroupMissingT_co]
```

Noded edges with at least one free end, grouped by source row.

### invalid\_rings `instance-attribute`

```python
invalid_rings: Groups[GeometryArray[LineString] | GroupMissingT_co]
```

Invalid noded rings or duplicate edges, grouped by source row.

### polygons `instance-attribute`

```python
polygons: GeometryArray[Polygon]
```

The polygons formed from the noded linework.
