Skip to content

Commit

Permalink
added table with metrics to readme
Browse files Browse the repository at this point in the history
  • Loading branch information
ReykCS committed Feb 22, 2023
1 parent 5500fa9 commit 5480d52
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 14 deletions.
20 changes: 19 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,25 @@ Record the data by setting `record_data:=true` when starting up the ros structur

# Transform data and calculate metrics

To transform the dataset for later plotting and calculate the metrics from the recorded data run `python get_metrics.py --dir <DIR>`, whereas `dir` is the directory which is created in the recording phase.
To transform the dataset for later plotting and calculate the metrics from the recorded data run `python get_metrics.py --dir <DIR>`, whereas `dir` is the directory which is created in the recording phase. The metrics which are created are shown in the following table:

| Name | Datatype | Description |
| -------------------- | ------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------- |
| curvature | Float[] | The curvature of the planner for each <br>timestep calculated with the [menger curvature](https://en.wikipedia.org/wiki/Menger_curvature) |
| normalized curvature | Float[] | The curvature multiplied by the length of the<br> path for this specific part. |
| roughness | Float[] | Describes how sudden and abrupt the planner changes directions. |
| path length | Float | The complete length of the part |
| path length values | Float[] | The length of each path between two continuous timestamps |
| acceleration | Float[] | The acceleration of the robot. Calculated as the gradient between two velocities. |
| jerk | Float[] | Describes the change in acceleration. |
| velocity | Float[][] | The real velocity of the robot. |
| cmd_vel | Float[][] | The robots desired velocity denoted by the planner |
| collision amount | Int | Absolute amount of collisions in an episode. |
| collisions | Int[] | Index of the positions in which a collision occured. |
| path | Float[][] | Array of positions in which the robot was located for specific timestamps. |
| angle over length | Float | The complete angle over the complete length of the path the robot took. |
| time diff | Int | The complete time of the episode. |
| result | TIMEOUT \| GOAL_REACHED \| COLLISION | The reason the episode has ended. |

# Plot Data

Expand Down
26 changes: 13 additions & 13 deletions plot_declarations/eval_iros_2023.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ results:
plot: true
# Title of the plot
title: Results
hue: local_planner
differentiate: local_planner
# Name of the file the plot should be saved ot
save_name: results
# Additional Plot arguments
Expand All @@ -50,7 +50,7 @@ single_episode_line:
# Number of values that should be skipped to reduce datapoints
step_size: 2 # Optional -> Defaults to 5
# Coloumn for differentiation
hue: local_planner # Optional -> Defaults to namespace
differentiate: local_planner # Optional -> Defaults to namespace
# Index of the episode -> If none all episodes are plotted
episode: 1 # Optional -> Defaults to none
title: Curvature
Expand All @@ -60,7 +60,7 @@ single_episode_line:
# Number of values that should be skipped to reduce datapoints
step_size: 2 # Optional -> Defaults to 5
# Coloumn for differentiation
hue: local_planner # Optional -> Defaults to namespace
differentiate: local_planner # Optional -> Defaults to namespace
# Index of the episode -> If none all episodes are plotted
episode: 1 # Optional -> Defaults to none
title: Roughness
Expand All @@ -70,7 +70,7 @@ single_episode_line:
# Number of values that should be skipped to reduce datapoints
step_size: 2 # Optional -> Defaults to 5
# Coloumn for differentiation
hue: local_planner # Optional -> Defaults to namespace
differentiate: local_planner # Optional -> Defaults to namespace
# Index of the episode -> If none all episodes are plotted
episode: 1 # Optional -> Defaults to none
title: Path Length
Expand All @@ -80,7 +80,7 @@ single_episode_line:
# Number of values that should be skipped to reduce datapoints
step_size: 2 # Optional -> Defaults to 5
# Coloumn for differentiation
hue: local_planner # Optional -> Defaults to namespace
differentiate: local_planner # Optional -> Defaults to namespace
# Index of the episode -> If none all episodes are plotted
episode: 1 # Optional -> Defaults to none
title: Acceleration
Expand All @@ -90,7 +90,7 @@ single_episode_line:
# Number of values that should be skipped to reduce datapoints
step_size: 2 # Optional -> Defaults to 5
# Coloumn for differentiation
hue: local_planner # Optional -> Defaults to namespace
differentiate: local_planner # Optional -> Defaults to namespace
# Index of the episode -> If none all episodes are plotted
episode: 1 # Optional -> Defaults to none
title: Jerk
Expand All @@ -100,7 +100,7 @@ single_episode_line:
# Number of values that should be skipped to reduce datapoints
step_size: 2 # Optional -> Defaults to 5
# Coloumn for differentiation
hue: local_planner # Optional -> Defaults to namespace
differentiate: local_planner # Optional -> Defaults to namespace
# Index of the episode -> If none all episodes are plotted
episode: 1 # Optional -> Defaults to none
title: Velocity
Expand All @@ -116,42 +116,42 @@ single_episode_distribution:
plot_key: "box"
title: Curvature
save_name: dist_episode_curvature
hue: local_planner
differentiate: local_planner
plot_args: {} # Optional
- data_key: roughness
episode: 1
plot_key: "box"
title: Roughness
save_name: dist_episode_roughness
hue: local_planner
differentiate: local_planner
plot_args: {} # Optional
- data_key: path_length_values
episode: 1
plot_key: "box"
title: Path Length
save_name: dist_episode_path_length_values
hue: local_planner
differentiate: local_planner
plot_args: {} # Optional
- data_key: acceleration
episode: 1
plot_key: "box"
title: Acceleration
save_name: dist_episode_acceleration
hue: local_planner
differentiate: local_planner
plot_args: {} # Optional
- data_key: jerk
episode: 1
plot_key: "box"
title: Jerk
save_name: dist_episode_jerk
hue: local_planner
differentiate: local_planner
plot_args: {} # Optional
- data_key: velocity
episode: 1
plot_key: "box"
title: Velocity
save_name: dist_episode_velocity
hue: local_planner
differentiate: local_planner
plot_args: {} # Optional

# - A line plot showing aggregated values for all episodes.
Expand Down

0 comments on commit 5480d52

Please sign in to comment.