Road segments
The Road segment type (RoadSegmentDatasetDTO) represents an individual segment of an OSM road, with detailed parking statistics for that precise segment.
Description
Unlike Roads, which aggregate data across an entire way, segments enable fine-grained analysis of parking. Each OSM road is split into segments of homogeneous length, making it possible to visualize density variations along a single street.
Relationship with Roads
OSM road "Rue des Lilas" (osm_id: way/123456789)
│
├── Segment 0 (id: way/123456789_0)
│ └── 5 spots catalogued
│
├── Segment 1 (id: way/123456789_1)
│ └── 12 spots catalogued
│
├── Segment 2 (id: way/123456789_2)
│ └── 0 spots (no-parking area)
│
└── Segment 3 (id: way/123456789_3)
└── 8 spots catalogued
Properties
Identification
| Property | Type | Description | Example |
|---|---|---|---|
id | string | Unique identifier ({osm_id}_{segment_index}) | way/123456789_2 |
layer_type | string | Document type | road_segment |
osm_id | string | OSM identifier of the parent road | way/123456789 |
segment_index | integer | Index of the segment along the road | 2 |
h3_index | string | H3 cell the segment is attached to | 893b0c6a9a7ffff |
Geometry
| Property | Type | Description |
|---|---|---|
geometry | LineString | Segment geometry (GeoJSON) |
Statistics
| Property | Type | Description |
|---|---|---|
segment_length_meters | number | Segment length in meters |
total_spots | integer | Number of spots catalogued on the segment |
avg_fit_score | number | Average confidence score (0-1) |
Traceability
| Property | Type | Description |
|---|---|---|
captured_at | datetime | Date of the most recent imagery for this segment |
Use cases
Graduated visualization
Use total_spots to build a map with a color gradient:
| Spot count | Suggested color | Interpretation |
|---|---|---|
| 0 | Grey | No parking |
| 1-5 | Light blue | Low density |
| 5-10 | Blue | Medium density |
| 10-50 | Dark blue | High density |
| 50+ | Very dark blue | Very high density |
Identifying critical areas
Analyze segments to spot:
- Segments with no parking (no-parking areas, double-parking)
- Concentrations of spots (linear parking)
- Density variations along a street
Analysis by H3 cell
Cross-reference segments with H3 cells to:
- Compute parking density per zone
- Compare provision between neighborhoods
- Identify under-served areas
Recommended QGIS style
To visualize segments with a gradient based on total_spots:
- Download the QGIS style file: road_segments.qml
- In QGIS: right-click on the layer → Properties → Symbology
- Style → Load Style → select the
.qmlfile
GeoJSON example
{
"type": "Feature",
"properties": {
"id": "way/123456789_2",
"layer_type": "road_segment",
"osm_id": "way/123456789",
"segment_index": 2,
"h3_index": "893b0c6a9a7ffff",
"segment_length_meters": 45.7,
"total_spots": 8,
"avg_fit_score": 0.82
},
"geometry": {
"type": "LineString",
"coordinates": [[55.47, -21.12], [55.475, -21.125]]
}
}
Relationship with other types
| Type | Relationship |
|---|---|
| Roads | A segment belongs to a road (via osm_id) |
| H3 cells | A segment belongs to an H3 cell (via h3_index) |
| Parking areas | Parking areas are located along segments |
Variants by source
Road segments come in two variants depending on the imagery source:
Street-level segments (road_segments_street)
Computed from street-level imagery. Each 20 m segment carries a detailed left/right analysis.
| Characteristic | Detail |
|---|---|
| Accuracy | ~1-2 meters |
| Attributes | Left/right distinction, parking type per side |
| Search radius | 10 meters around the segment |
Satellite segments (road_segments_satellite)
Computed from HD satellite imagery. Aggregation is global per segment (no left/right distinction, since the nadir view does not allow for it).
| Characteristic | Detail |
|---|---|
| Accuracy | ~3-5 meters |
| Attributes | Total spots per segment only |
| Search radius | 15 meters around the segment |
| Road filtering | Motorways, pedestrian ways and cycle paths excluded |
Both variants share the same data format (RoadSegmentDatasetDTO), the same geometry (20-meter segments), and the same confidence scoring (avg_fit_score).