Generate morphological tessellation around given buildings or proximity bands around
given street network.
See [FFRP20] for details of implementation.
Tessellation requires data of relatively high level of precision and there are three
particular patterns causign issues.
1. Features will collapse into empty polygon - these do not have tessellation
cell in the end.
2. Features will split into MultiPolygon - at some cases, features with narrow links
between parts split into two during ‘shrinking’. In most cases that is not an issue
and resulting tessellation is correct anyway, but sometimes this result in a cell
being MultiPolygon, which is not correct.
3. Overlapping features - features which overlap even after ‘shrinking’ cause invalid
All three types can be tested prior momepy.Tessellation using momepy.CheckTessellationInput.
GeoDataFrame containing building footprints or street network
name of the column with unique id
MultiPolygon or Polygon defining the study area limiting tessellation (otherwise it could go to infinity).
distance for negative buffer to generate space between adjacent polygons (if geometry type of gdf is (Multi)Polygon).
maximum distance between points after discretization
if True, shows progress bars in loops and indication of steps
queen_corners is currently experimental method only and can cause errors.
>>> tess = mm.Tessellation(buildings_df, 'uID', limit=mm.buffered_limit(buildings_df))
Generating input point array...
100%|██████████| 144/144 [00:00<00:00, 376.15it/s]
Generating Voronoi diagram...
Vertices to Polygons: 100%|██████████| 33059/33059 [00:01<00:00, 31532.72it/s]
Dissolving Voronoi polygons...
Preparing buffer zone for edge resolving...
100%|██████████| 42/42 [00:00<00:00, 752.54it/s]
0 1 POLYGON ((1603586.677274485 6464344.667944215,...
1 2 POLYGON ((1603048.399497852 6464176.180701573,...
2 3 POLYGON ((1603071.342637536 6464158.863329805,...
3 4 POLYGON ((1603055.834005827 6464093.614718676,...
4 5 POLYGON ((1603106.417554705 6464130.215958447,...
GeoDataFrame containing resulting tessellation
Series containing used unique ID
used shrink value
used segment value
spatial index of tessellation
list of unique_id’s of collapsed features (if there are some)
list of unique_id’s of features causing MultiPolygons (if there are some)
Experimental function to fix unprecise corners.
Initialize self. See help(type(self)) for accurate signature.
__init__(gdf, unique_id, limit[, shrink, …])