MapElement¶
- class standard_e2e.data_structures.MapElement(**data)[source]¶
Bases:
BaseModelA single HD map element (polyline, polygon, or point) in vehicle frame.
points:(N, 2)or(N, 3)float32 array.N == 1is allowed for point-like elements (e.g.STOP_SIGN);N >= 2for polylines / polygons. Datasets that ship only XY (e.g. AV2, where vector Z is advisory and may be NaN outside the ground-height ROI) emit(N, 2); datasets with reliable 3D maps (Waymo) emit(N, 3). The BEV rasterizer slices[:, :2]and works for both.is_closed: True for polygons (last point connects to first); False for open polylines and points.successor_ids/predecessor_ids: lane-graph connectivity (empty for non-lane elements). Unused by the BEV rasterizer; kept on the schema for future vector-output adapters.left_neighbor_id/right_neighbor_id: lateral lane neighbours (None for non-lane elements). Single ID per side; if a source dataset ships a list, take the first.attrs: dataset-specific per-element metadata. Standardised keys documented indocs/map_element_translation.md(e.g.lane_type,is_intersection,speed_limit_mph,paint_color,paint_pattern,paint_subtype_raw,road_edge_subtype,tl_state_per_ts,controlled_lane_id).
- Parameters:
- type: MapElementType¶