navigation2
navigation2 copied to clipboard
Simple Commander Costmap API
Add a costmap API for OccupancyGrid messages coming into the Simple Commander API
Basically have the basic API from https://github.com/ros-planning/navigation2/blob/main/nav2_costmap_2d/include/nav2_costmap_2d/costmap_2d.hpp + adding global frame ID and timestamp with a constructor that takes in the OccupancyGrid.
Potentially even a python collision checker too when given a footprint from the footprint topic + this new CostmapPy class
For someone who is going to implement it, we have something something similar, which can be found under https://github.com/neobotix/neo_nav2_py_costmap2D ! But it would be actually nice to have it as part of the nav2 ecosystem.
(wish it was me, but unfortunately I don't have time until october to get into this)
I would love to try it, is t possible?
Absolutely!
I would like to contribute as well, let me know what I can do!
Same here, let me know if you need some help with it :)
I would love to contribute. Let me know if we can do it as a team. @SteveMacenski @afifswaidan @igrak34 @stevedanomodolor
I would love to contribute. Let me know if we can do it as a team. @SteveMacenski @afifswaidan @igrak34 @stevedanomodolor
I have no problem from my side, count me in.
I would love to contribute. Let me know if we can do it as a team. @SteveMacenski @afifswaidan @igrak34 @stevedanomodolor
Sure me too, I don't mind
I would like to contribute. But, I am not so familiar with ROS2, but familiar with ROS1. Can I try to contribute with as a team? @SteveMacenski @afifswaidan @igrak34 @stevedanomodolor
Awesome!
So the general things that need to be implemented are those in the files I linked to above, namely a class PyCostmap2D
- A: Constructor for OccupancyGrid which stores the relevant information
- A: getSizeInCellsX / getSizeInCellsY
- A: getSizeInMetersX / getSizeInMetersY
- A: getOriginX / getOriginY
- A: getResolution
- A: getGlobalFrameID
- A: getCostmapTimestamp
- B: getCost at map pixels and index
- B: setCost at map pixels
- B: mapToWorld
- B: worldToMap
- B: getIndex
That's 1 item and once that's done another person could contribute a costmap collision checker, where the object should take in this costmap object + a footprint to perform collision checking, perhaps using @padhupradheep 's line iterator: https://github.com/neobotix/neo_nav2_py_costmap2D/blob/main/neo_nav2_py_costmap2D/line_iterator.py analogous to https://github.com/ros-planning/navigation2/blob/main/nav2_costmap_2d/include/nav2_costmap_2d/footprint_collision_checker.hpp
I think there are a couple of natural roles here to help!
- Person A: Implement the PyCostmap2D class's first few functions marked in "A"
- Person B: Implement the methods for converting / getting information from the occupancy grid after the core API is done
- Person C: Implement and test a line iterator to march through the costmap given 2 points and check for collision
- Person D: Use that line iterator + costmap object + footprint input to check for collisions!
Who wants to get started with A and C? I think those can both be worked on in parallel
@SteveMacenski I can get started with A
@SteveMacenski If I can do, I want to do the role of B.
I just created a draft pull request https://github.com/ros-planning/navigation2/pull/3159. I should have this done by the end of tomorrow.
Awesome!
So the general things that need to be implemented are those in the files I linked to above, namely a class
PyCostmap2D
- A: Constructor for OccupancyGrid which stores the relevant information
- A: getSizeInCellsX / getSizeInCellsY
- A: getSizeInMetersX / getSizeInMetersY
- A: getOriginX / getOriginY
- A: getResolution
- A: getGlobalFrameID
- A: getCostmapTimestamp
- B: getCost at map pixels and index
- B: setCost at map pixels
- B: mapToWorld
- B: worldToMap
- B: getIndex
That's 1 item and once that's done another person could contribute a costmap collision checker, where the object should take in this costmap object + a footprint to perform collision checking, perhaps using @padhupradheep 's line iterator: https://github.com/neobotix/neo_nav2_py_costmap2D/blob/main/neo_nav2_py_costmap2D/line_iterator.py analogous to https://github.com/ros-planning/navigation2/blob/main/nav2_costmap_2d/include/nav2_costmap_2d/footprint_collision_checker.hpp
I think there are a couple of natural roles here to help!
- Person A: Implement the PyCostmap2D class's first few functions marked in "A"
- Person B: Implement the methods for converting / getting information from the occupancy grid after the core API is done
- Person C: Implement and test a line iterator to march through the costmap given 2 points and check for collision
- Person D: Use that line iterator + costmap object + footprint input to check for collisions!
Who wants to get started with A and C? I think those can both be worked on in parallel
Hello,
So I guess A is taken, you need now someone for C. I can handle C if you want.
@SteveMacenski how do you think it's best to organize and kickoff the group work and track the progress?
We can use something like this, @SteveMacenski @afifswaidan
Task tracking
| Author | Task assigned | Task Completed | Pull request Accepted | Task Dependency |
|---|---|---|---|---|
| @stevedanomodolor | A | ❌ | ❌ | - |
| @JacksonK9 | B | ❌ | ❌ | A |
| @afifswaidan | C | ❌ | ❌ | - |
| --- | D | ❌ | ❌ | A B C |
So, A, B, and C are taken?
For D I think we have to collaborate somehow as it depends upon A,B and C.
We can use something like this, @SteveMacenski @afifswaidan
Task tracking
Author Task assigned Task Completed Pull request Accepted Task Dependency @stevedanomodolor A ❌ ❌ - --- B ❌ ❌ A --- C ❌ ❌ - --- D ❌ ❌ A B C
Sounds good, I'll take C then, please add me to the table :)
@manishsaini0901 do you want take over the task?, Someone has to make the changes even though you might require inputs from authors of the other tasks
Updated on task: @JacksonK9 @afifswaidan @SteveMacenski
Task tracking
| Author | Task assigned | Task Completed | Pull request Accepted | Task Dependency |
|---|---|---|---|---|
| @stevedanomodolor | A | ✅ | ✅ | - |
| @JacksonK9 | B | ❌ | ❌ | A |
| @afifswaidan | C | ❌ | ❌ | - |
| --- | D | ❌ | ❌ | A B C |
@stevedanomodolor Can I start with your github repository? or Do I have to wait for the acception of Pull Request?
@JacksonK9 I think I would wait when my pull request is accepted. You can fork directly from navigation2 if my pull request is merged to have the current main. If we do the pull in the end of finishing the whole task, you might have to use my own fork
@stevedanomodolor Okay, I understand.
@SteveMacenski Which is better? Can I start with official nav2 repository after the acception of Pull Request? or Just start with stevedanomodolor's nav2 repository?
@JacksonK9 if my pull is accepted you can use the official directly
Task A done and merged!
@SteveMacenski Thank you maybe, I can finish the task B until the end of this week.
https://github.com/ros-planning/navigation2/issues/3149 This is another good Python3 project if folks were interested!
@SteveMacenski I can try it this weekend,
@SteveMacenski for task C I already started implementing, but I need some more functions in the costmap_2d class(i.e MapToWorld, etc...) Should I add these as well to the costmap_2d.py file that was committed 3 days ago or @stevedanomodolor is already working/committing them? Just to know if I should wait or go ahead and implement them to continue working on Task C.