japan op• Data kinds: table → table
• Call: import fullseye as fs; fs.ledger.osm_road_loops(roadmask: 'dict', *, tolerance_px: 'float' = 0.75) -> 'Dict[str, object]' (to call the implementation directly, import drivejapan; drivejapan.osm_road_loops(roadmask: 'dict', *, tolerance_px: 'float' = 0.75) -> 'Dict[str, object]'; from the registry, opsdrive.get("osm_road_loops"))
• GPU: none (CPU reference implementation only)
Boundary loops of the union of roads. Splits them into outer loops (road edges) and holes (city blocks) and simplifies them with Douglas–Peucker.
The tracing follows pixel edges (contours_xld._trace_mask_boundaries), so the sum of loop areas before decimation = number of pixels × step² (outer − holes) holds exactly (area_check). Whether a loop is a hole or outer is decided by whether the pixel just to the right of the loop's leftmost vertical edge is road. Return value {"outer": [(K,2) xy], "holes": [(K,2) xy], "outer_raw", "holes_raw", "area_check": {"loops_m2", "pixels_m2", "abs_err"}}.
Empty input (roadmask is an empty dict) raises ValueError.
• Sample-data catalog (download URLs / licences) — 2-D uses skimage.data (BSD/public domain) plus synthetic images; 3-D lists download URLs for real data sources (Stanford, PDS, …).
• Operator provenance and references — the sources of the research/methods this op family came from.
• The canonical algorithm (author, year) and its uses are named in the family usage guide above.
• poc_driving_japan_town — py -3.11 examples/poc_driving_japan_town.py
table as input)course_layout · course_occupancy · course_contains · world_build · world_camera · world_move · lidar_scan · rss_longitudinal_same
japan)osm_synthetic · osm_parse · osm_road_graph · osm_road_mask · osm_route · japan_world · japan_stats · latlon_to_local
*Provenance: drivejapan.py — DRIVE operator registry. This per-op note is generated by tools/opdocs.py md (do not hand-edit).*
© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.