diff --git a/docs/demos/images/planning/passing-crosswalk/non-signalized/initial-setup.png b/docs/demos/images/planning/passing-crosswalk/non-signalized/initial-setup.png new file mode 100644 index 00000000000..ac820e4ad39 Binary files /dev/null and b/docs/demos/images/planning/passing-crosswalk/non-signalized/initial-setup.png differ diff --git a/docs/demos/images/planning/passing-crosswalk/non-signalized/pass-crosswalk.png b/docs/demos/images/planning/passing-crosswalk/non-signalized/pass-crosswalk.png new file mode 100644 index 00000000000..cd8119ee292 Binary files /dev/null and b/docs/demos/images/planning/passing-crosswalk/non-signalized/pass-crosswalk.png differ diff --git a/docs/demos/images/planning/passing-crosswalk/non-signalized/place-pedestrian.png b/docs/demos/images/planning/passing-crosswalk/non-signalized/place-pedestrian.png new file mode 100644 index 00000000000..6296f92aa4c Binary files /dev/null and b/docs/demos/images/planning/passing-crosswalk/non-signalized/place-pedestrian.png differ diff --git a/docs/demos/images/planning/passing-crosswalk/non-signalized/wait-before-crosswalk.png b/docs/demos/images/planning/passing-crosswalk/non-signalized/wait-before-crosswalk.png new file mode 100644 index 00000000000..feb9fde7e53 Binary files /dev/null and b/docs/demos/images/planning/passing-crosswalk/non-signalized/wait-before-crosswalk.png differ diff --git a/docs/demos/images/planning/passing-crosswalk/signalized/move-after-red-to-green.png b/docs/demos/images/planning/passing-crosswalk/signalized/move-after-red-to-green.png new file mode 100644 index 00000000000..e4457c0c17e Binary files /dev/null and b/docs/demos/images/planning/passing-crosswalk/signalized/move-after-red-to-green.png differ diff --git a/docs/demos/images/planning/passing-crosswalk/signalized/stop-from-red-and-pedestrian.png b/docs/demos/images/planning/passing-crosswalk/signalized/stop-from-red-and-pedestrian.png new file mode 100644 index 00000000000..8d0f9fba184 Binary files /dev/null and b/docs/demos/images/planning/passing-crosswalk/signalized/stop-from-red-and-pedestrian.png differ diff --git a/docs/demos/images/planning/passing-crosswalk/signalized/stop-from-red-light.png b/docs/demos/images/planning/passing-crosswalk/signalized/stop-from-red-light.png new file mode 100644 index 00000000000..187a5204407 Binary files /dev/null and b/docs/demos/images/planning/passing-crosswalk/signalized/stop-from-red-light.png differ diff --git a/docs/demos/images/planning/passing-crosswalk/signalized/stop-red-light-with-pedestrian.png b/docs/demos/images/planning/passing-crosswalk/signalized/stop-red-light-with-pedestrian.png new file mode 100644 index 00000000000..e199161b241 Binary files /dev/null and b/docs/demos/images/planning/passing-crosswalk/signalized/stop-red-light-with-pedestrian.png differ diff --git a/docs/demos/images/planning/passing-crosswalk/signalized/test-location.png b/docs/demos/images/planning/passing-crosswalk/signalized/test-location.png new file mode 100644 index 00000000000..c06e7e1c829 Binary files /dev/null and b/docs/demos/images/planning/passing-crosswalk/signalized/test-location.png differ diff --git a/docs/demos/images/planning/passing-crosswalk/signalized/wait-for-pedestrian.png b/docs/demos/images/planning/passing-crosswalk/signalized/wait-for-pedestrian.png new file mode 100644 index 00000000000..2fecf39e6d8 Binary files /dev/null and b/docs/demos/images/planning/passing-crosswalk/signalized/wait-for-pedestrian.png differ diff --git a/docs/demos/planning-simulation.md b/docs/demos/planning-simulation.md index 327f7b4a4d4..cb258297a09 100644 --- a/docs/demos/planning-simulation.md +++ b/docs/demos/planning-simulation.md @@ -171,13 +171,17 @@ After that, `Auto` button will be selected and grayed out. 4. Delete any dummy objects placed in the view by clicking the `Delete All Objects` button in the toolbar and then click anywhere in the 3D View pane to complete it. -5. Click the `Interactive` button in the toolbar to create the next dummy object in interactive mode. +#### Placing interactive dummy objects - ![set-interactive-dummy-car](images/planning/lane-following/check-interactive.png) +Click the `Interactive` button in the toolbar to create the next dummy object in interactive mode. -6. To add/place an interactive dummy object, press `SHIFT` and click the `right click`. -7. To delete an interactive dummy object, press `ALT` and click the `right click`. -8. To move an interactive dummy object, hold the `right click` drag and drop the object. +![set-interactive-dummy-car](images/planning/lane-following/check-interactive.png) + +!!! info + + - **Add an interactive dummy object:** ++shift+"🖱️ Right Click"++ on the map. + - **Delete an interactive dummy object:** ++alt+"🖱️ Right Click"++ on the object. + - **Move an existing interactive dummy object:** ++"🖱️ Right Click"++ and hold on the object. Then drag and drop it to the desired location. ### Traffic light recognition simulation @@ -218,6 +222,112 @@ To remove a traffic light from `TrafficLightPublishPanel`, click the `RESET` but [Reference video tutorials](https://drive.google.com/file/d/1bs_dX1JJ76qHk-SGvS6YF9gmekkN8fz7/view?usp=sharing) +### Driving through a crosswalk + +When driving through a crosswalk, the ego vehicle evaluates **both** the presence of pedestrians/objects **and** the state of any associated traffic lights. + +!!! info + + For more technical details, refer to the [**autoware_behavior_velocity_crosswalk_module** documentation](https://autowarefoundation.github.io/autoware_universe/main/planning/behavior_velocity_planner/autoware_behavior_velocity_crosswalk_module/). + +!!! info + + These examples use the **Nishishinjuku** map, the same one used in the [lane change scenario](#lane-change-scenario). + +!!! tip + + For these tutorials, it is easier to use **interactive dummy pedestrians** (see [Placing interactive dummy objects](#placing-interactive-dummy-objects) above). + + This way you can quickly add, move, and delete dummy pedestrians as needed. + +#### Non-signalized crosswalk (no traffic light) + +##### Behavior logic + +```mermaid +flowchart TD + A["Approach **crosswalk**"] --> B{"Pedestrian somewhere on the **crosswalk**?
(Pedestrian velocity is not important.)"} + B -- "No" --> C["Proceed without slowing down"] + B -- "Yes" --> D["Slow down and stop **one time**"] + D --> E["Wait a few seconds to confirm safe to proceed"] + E --> F{"Pedestrian or object on **planned path**?"} + F -- "Yes" --> G["Continue waiting / yield"] + F -- "No" --> H["Resume driving (will not stop again for this crosswalk)"] + H --> I["Crosswalk passed ➡️ behavior resets when encountering the same crosswalk again"] +``` + +!!! example "Experiment" + + We will test the expected “single stop then go” behavior: + + 1. Place a still dummy pedestrian on the crosswalk. (Not on the planned path, just on the crosswalk.) + + 2. The ego vehicle will decelerate and stop before the crosswalk. + + 3. After waiting for a few seconds, the ego vehicle will start driving again as usual. + +1. Set an initial pose and a goal pose for the ego vehicle to drive through a non-signalized crosswalk. A path will be planned. + + ![initial-setup](images/planning/passing-crosswalk/non-signalized/initial-setup.png) + +2. Place an interactive dummy pedestrian on the crosswalk and set its pose as if it is crossing the street. It doesn't matter whether the dummy pedestrian is moving or not, as long as it is on the crosswalk. + + ![place-pedestrian](images/planning/passing-crosswalk/non-signalized/place-pedestrian.png) + +3. Engage the ego vehicle by clicking on `Auto`. The ego vehicle will decelerate and stop before the crosswalk. The marked **crosswalk** in the figure indicates that the stopping behavior is caused by the objects on the **crosswalk**. + + ![wait-before-crosswalk](images/planning/passing-crosswalk/non-signalized/wait-before-crosswalk.png) + +4. The ego vehicle will wait for about a few seconds. Then it will start moving again and pass the crosswalk. + + ![pass-crosswalk](images/planning/passing-crosswalk/non-signalized/pass-crosswalk.png) + +#### Signalized crosswalk (with traffic light) + +
+ ![test-location.png](images/planning/passing-crosswalk/signalized/test-location.png) +
Location for signalized crosswalk experiments
+
+ +!!! example "Experiment 1: Pedestrian Present While Traffic Light Is GREEN" + + This experiment mirrors the previous one but at a signalized crosswalk. + +With the pedestrian near the path and the traffic light **GREEN**, the ego behaves **the same as at a non-signalized crosswalk**: +it slows, stops, waits, then continues. + +![wait-for-pedestrian](images/planning/passing-crosswalk/signalized/wait-for-pedestrian.png) + +!!! example "Experiment 2: Interaction of Pedestrians and a RED Traffic Light" + + 1. Stop before the crosswalk when the traffic light is set to `RED`. (Without pedestrians.) + + 2. Add a dummy pedestrian on the crosswalk while the traffic light is `RED`. (Both the traffic light and the crosswalk should affect the stopping behavior.) + + 3. Finally, set the traffic light to `GREEN` again and the vehicle will pass normally. + +1. **Stop at red (no pedestrians).** + Remove any existing dummy pedestrians and set the traffic light to **RED**. + The ego vehicle will stop before the crosswalk and wait solely because of the **traffic_light** reason. + + ![stop-from-red-light](images/planning/passing-crosswalk/signalized/stop-from-red-light.png) + +2. **Add a pedestrian while the light is RED.** + The ego remains stopped, now influenced by **both** the traffic light and the crosswalk object. + + ![stop-from-red-and-pedestrian](images/planning/passing-crosswalk/signalized/stop-from-red-and-pedestrian.png) + +3. **Observe how the stop reasons update.** + After a short period, only **traffic_light** may remain displayed. + Moving the pedestrian slightly (with ++shift+"🖱️ Right Click"++ drag) reintroduces both markers, but the system stabilizes back to the traffic-light reason during the wait. + + ![stop-red-light-with-pedestrian.png](images/planning/passing-crosswalk/signalized/stop-red-light-with-pedestrian.png) + +4. **Switch the light to GREEN.** + When set to green and `Auto` mode is engaged, the ego vehicle proceeds normally. + + ![move-after-red-to-green.png](images/planning/passing-crosswalk/signalized/move-after-red-to-green.png) + ## Using Autoware Launch GUI This section provides a step-by-step guide on using the Autoware Launch GUI for planning simulations, offering an alternative to the command-line instructions provided in the Basic simulations section.