From a28f387e543dcbce8972cef9e31161c2f4ab5da6 Mon Sep 17 00:00:00 2001 From: Tony Najjar Date: Wed, 10 Jan 2024 21:51:31 +0000 Subject: [PATCH 1/2] test Signed-off-by: Tony Najjar --- .../nav2_simple_commander/costmap_2d.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/nav2_simple_commander/nav2_simple_commander/costmap_2d.py b/nav2_simple_commander/nav2_simple_commander/costmap_2d.py index 2ddc9cb00f..db63a80d98 100644 --- a/nav2_simple_commander/nav2_simple_commander/costmap_2d.py +++ b/nav2_simple_commander/nav2_simple_commander/costmap_2d.py @@ -34,6 +34,15 @@ class PyCostmap2D: """ def __init__(self, occupancy_map): + """ + Initialize costmap2D. + + Args + ---- + occupancy_map: OccupancyGrid + 2D OccupancyGrid Map + + """ self.size_x = occupancy_map.info.width self.size_y = occupancy_map.info.height self.resolution = occupancy_map.info.resolution From 83833b6a4c88e3fc91381a584ca52c0b52514f81 Mon Sep 17 00:00:00 2001 From: Tony Najjar Date: Wed, 10 Jan 2024 21:57:27 +0000 Subject: [PATCH 2/2] . Signed-off-by: Tony Najjar --- nav2_simple_commander/nav2_simple_commander/costmap_2d.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/nav2_simple_commander/nav2_simple_commander/costmap_2d.py b/nav2_simple_commander/nav2_simple_commander/costmap_2d.py index db63a80d98..ad4014522a 100644 --- a/nav2_simple_commander/nav2_simple_commander/costmap_2d.py +++ b/nav2_simple_commander/nav2_simple_commander/costmap_2d.py @@ -39,8 +39,11 @@ def __init__(self, occupancy_map): Args ---- - occupancy_map: OccupancyGrid - 2D OccupancyGrid Map + occupancy_map (OccupancyGrid): 2D OccupancyGrid Map + + Returns + ------- + None """ self.size_x = occupancy_map.info.width