town_rules — DRIVE town op

• Data kinds: none → table (an op determined by its arguments alone — it takes no image or data input)

• Call: import fullseye as fs; fs.ledger.town_rules(jurisdiction: 'str' = 'JP') -> 'dict' (to call the implementation directly, import drivetown; drivetown.town_rules(jurisdiction: 'str' = 'JP') -> 'dict'; from the registry, opsdrive.get("town_rules"))

Usage

Rule pack (a copy of RULE_PACKS). {"jurisdiction", "side": "left"|"right", "crossing_stop": "always"|"when_active", "intersection_stop": "signal", "hold_s", "look_required", "look_hold_s", "sources": [...], "verified", "notes"}.

JP = left-hand traffic, always stop + safety check at railway crossings (Road Traffic Act (Japan) Article 33 Paragraph 1, confirmed in the text → verified True). US = right-hand traffic, ordinary vehicles stop only while the warning is active (state law. No primary confirmation → verified False). DE = right-hand traffic, under StVO §19 only while the barrier/lights are operating (no primary confirmation → verified False). Rules with verified False are not stated as definitive in PoCs or reports.

Raises ValueError: unknown jurisdiction.

References (sample data, literature)

• 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.

Runnable examples (verified samples that actually call this op)

• poc_driving_town — py -3.11 examples/poc_driving_town.py

Ops the type connects to (they accept table as input)

course_layout · course_occupancy · course_contains · world_build · world_camera · world_move · lidar_scan · rss_longitudinal_same

Same category (town)

town_chain · town_layout · town_world · town_centerline · town_stop_lines · town_crossing_state · town_run · town_checks


*Provenance: drivetown.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.