Skip to content

Dense Ring Polygon (4096 vertices)

vectorGeoJSONPolygonEPSG:4326smallbundled

A 17-lobed closed ring sampled at 4096 vertices, generated from r(theta) = radius * (1 + 0.18cos(17theta)). The vertex count is the point: it is an exact dial, chosen to exceed the buffer sizes and per-feature limits that low-vertex fixtures never reach.

Polygon geometry of dense_ring_polygon_4k, rendered from the case's data
Polygon geometry, rendered from the case's actual geometry. Scale is normalized to the viewport and is not comparable between cases.
Property Value
Case ID dense_ring_polygon_4k
Category vector
Format GeoJSON
Geometry type Polygon
CRS EPSG:4326
Location South Africa, Free State (synthetic) — 23.51°E, 32.01°S → 26.32°E, 29.19°S
Test tier unit
Size class small
Storage class bundled
Redistributable yes
Loader geopandas
Status validated

Use this case

import pytest


@pytest.mark.geocase_case("dense_ring_polygon_4k")
def test_dense_ring_polygon_4k(geocase_case) -> None:
    data = geocase_case.load()
    assert data is not None

Use GeoCase in your tests

Install the complete set of vector, raster, and NetCDF dependencies:

pip install "geocase[all]"

View GeoCase on PyPI.

What this case checks

Confirm that a 4096-vertex polygon survives loading with every coordinate intact and the ring still closed -- catching fixed-size coordinate buffers, silent decimation, and per-feature vertex caps.

Expected behavior

Assertion Expected
expect_loadable yes
expect_valid_geometry yes
expect_crs yes
expected_epsg 4326
expected_geometry_types Polygon

Notes

What this is

A closed ring sampled at 4096 equal angular steps from

r(theta) = 1.2 * (1 + 0.18 * cos(17 * theta))

centred at 24.9E / 30.6S. Seventeen lobes, so the shape is unmistakably not a circle at any zoom, and the ring is simple -- the amplitude is well under the value at which the lobes would fold back and self-intersect.

Why it exists

vertices is an exact dial. That is the whole design: fixture size is chosen up front rather than discovered after writing, so this case can sit precisely where it is useful -- past the point where a fixed-size coordinate buffer overflows, a per-feature vertex cap trips, or a "helpful" simplification pass starts dropping detail, while still landing comfortably inside the generator's 256 KB non-SpatiaLite budget. The size is asserted by tests/unit/test_generated_geometry.py rather than trusted to that estimate.

The catalog's next-densest geometry has ten vertices, so nothing else in it exercises this axis at all.

How it is produced

Generated by scripts/generate_vector_fixtures.py (_dense_parametric_ring), from pure math with no PRNG -- see fractal_coastline_polygon's notes for why that matters to the byte-identical regeneration gate. Coordinates are rounded to six decimals.

Not a member of the cross-format transcoding family: it declares no canonical_source_case_id and carries no cross_format_canonical tag. The sibling case dense_ring_polygon_4k_gpkg records the same geometry through a GeoPackage driver, so the vertex count is exercised through a real writer as well as through hand-written JSON.

Required capabilities

  • load
  • bounds-check
  • geometry-validation

Files

Browse this case on GitHub

Source and license

  • Source: geocase-curated
  • License: MIT

Tags

high_vertex_count irregular_geometry polygon procedural valid vector