From 8e8954b98a003ab627512a858bdd4770fd312986 Mon Sep 17 00:00:00 2001 From: Ahmed Ebrahim Date: Mon, 13 May 2024 07:55:46 +0300 Subject: [PATCH] feat(remaining_dist_eta): update readme Signed-off-by: Ahmed Ebrahim --- .../README.md | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/planning/autoware_remaining_distance_time_calculator/README.md b/planning/autoware_remaining_distance_time_calculator/README.md index 10eaf63c21d55..34eb2fffae3bc 100644 --- a/planning/autoware_remaining_distance_time_calculator/README.md +++ b/planning/autoware_remaining_distance_time_calculator/README.md @@ -15,22 +15,24 @@ This package aims to provide mission remaining distance and remaining time calcu | ------------- | ------ | ------------- | --------------------------- | | `update_rate` | double | 10.0 | Timer callback period. [Hz] | -### Inner-workings / Algorithms +### Inner-workings -### Remaining Distance Calculation +#### Remaining Distance Calculation - The remaining distance calculation is based on getting the remaining shortest path between the current vehicle pose and goal pose using `lanelet2` routing APIs. - The remaining distance is calculated by summing the 2D length of remaining shortest path, with exception to current lanelet and goal lanelet - For the current lanelet, the distance is calculated from the current vehicle position to the end of that lanelet - For the goal lanelet, the distance is calculated from the start of the lanelet to the goal pose in this lanelet. +- When there is only one lanelet remaining, the distance is calculated by getting the 2D distance between the current vehicle pose and goal pose. +- Checks are added to handle cases when current lanelent, goal lanelet, or routing graph are not valid to prevent node process die + - In such cases when, last valid remaining distance and time are maintained -### Remaining Time Calculation +#### Remaining Time Calculation -- Remaining time is calculated using simple equation of motion by getting the current vehicle velocity magnitude. -- Then the calculated remaining distance is divided by the velocity magnitude. +- The remaining time currently depends on a simple equation of motion by getting the maximum velocity limit. +- The remaining distance is calculated by dividing remaining distance by the maximum velocity limit ### Future Work - Find a more efficient way for remaining distance calculation instead of regularly searching the graph for finding the remaining shortest path -- Engage more sophisticated motion models for more accurate remaining time calculations -- Handle cases when the vehicle stops during the mission or Autoware get disengaged then engaged for the same mission +- Engage more sophisticated motion models for more accurate remaining time calculations \ No newline at end of file