-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add space nav2 #80
Add space nav2 #80
Conversation
This is the first PR for: space-ros/space-ros#67 |
60acc19
to
23ce28d
Compare
@mkhansenbot I have just tested it locally. I have successfully build the docker image and run it.
Anyway, is there any demos inside which should I test? |
Good catch, I found the issue and will push a fix today. I'll also add a README with instructions. I can currently run the mars_rover demo, along with Nav2 and SLAM, however, SLAM doesn't work yet because I need to add a lidar and encoders to the model to have it publish the |
Hi @mkhansenbot |
I think the odometry can be solved by adding a |
0eeebe4
to
a242b7d
Compare
This is now ready for review. I moved the demo specific files into a separate folder "nav2_demo" and moved the instructions for running the demo into the README in that folder. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haven't built and tested yet but here are some preliminary comments
nav2_demo/Dockerfile
Outdated
LABEL org.label-schema.vendor="Open Robotics" | ||
LABEL org.label-schema.version=${VERSION} | ||
LABEL org.label-schema.url="https://github.com/space-ros" | ||
LABEL org.label-schema.vcs-url="https://github.com/space-ros/docker-images" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LABEL org.label-schema.vcs-url="https://github.com/space-ros/docker-images" | |
LABEL org.label-schema.vcs-url="https://github.com/space-ros/docker" |
COPY mars_map* /home/spaceros-user/nav2_ws | ||
|
||
# Install nav2 config file for mars rover demo | ||
COPY nav2_params.yaml /home/spaceros-user/nav2_ws |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should be able to use the NAVIGATION2_WS
variable (maybe as a build arg instead of env var) but I know variable expansion in COPY
expressions has been difficult in the past so I'm going to test this myself before adding a suggested patch.
nav2_demo/README.md
Outdated
# Run the Mars Rover demo with Nav2 and SLAM toolbox | ||
|
||
## Terminal 1 - launch the mars_rover demo | ||
Follow instructions on space-ros/docker/space-robots/README.md |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Follow instructions on space-ros/docker/space-robots/README.md | |
Follow instructions in the [space-robots `README.md`](../space-robots/README.md) |
Exec into the same space_nav2 container and launch Rviz2 | ||
``` | ||
docker exec -it -e DISPLAY=:0 osrf_space_nav2_demo bash | ||
source /opt/ros/humble/setup.bash |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are we installing Space ROS and Humble in the nav container?
navigation2/README.md
Outdated
To build the docker image, run: | ||
|
||
``` | ||
$ ./build.sh |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This isn't consistent with how shell scripts are listed in the demo container README, we should make it consistent.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure what you mean by this, is it the leading $
that is different?
|
||
The new image is named **osrf/space_nav2:latest**. | ||
|
||
There is a run.sh script provided for convenience that will run the spaceros image in a container. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need to mention that rocker
is required here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can add it but I don't see it mentioned on the space_robots README, so we should be consistent. I added issue #128 to fix this.
navigation2/navigation2.repos
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since this is a demo, should we pin these to commits so they don't move out from under us?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since this same issue exists for the MoveIt2 demo, I created an issue so we can resolve it for both. #127
nav2_demo/README.md
Outdated
## Terminal 2 - launch Nav2 | ||
Start the space_nav2 container and launch the navigation2 nodes | ||
``` | ||
run.sh |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need to note that this requires rocker
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Filed issue #128
LABEL org.label-schema.vendor="Open Robotics" | ||
LABEL org.label-schema.version=${VERSION} | ||
LABEL org.label-schema.url="https://github.com/space-ros" | ||
LABEL org.label-schema.vcs-url="https://github.com/space-ros/docker-images" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LABEL org.label-schema.vcs-url="https://github.com/space-ros/docker-images" | |
LABEL org.label-schema.vcs-url="https://github.com/space-ros/docker" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@xfiderek should we copy the exclude packages text files pattern here now or hold off incase we convert to Earthfile in the next release?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you are asking in context of rosdep
then I would double check if we need rosdep commands at all in here. I think that unless Nav2 requires some non-ROS dependencies then it should not be required 1. @mkhansenbot have you by any chance tried to build this image without rosdep commands? If not maybe its worth trying / we can try together. Btw I see that list of skip keys here is a bit different than in spaceros base image. Is there a specific reason to that?
If it turns out that rosdep is needed I would already make use of text file, however I see that there is a divergence between:
- "excluded-pkgs.txt"
- skip keys in spaceros image
- skip keys in this image
so unless we can address the divergence soon, we need to postpone it.
On the side note (not related to this PR), your question @Bckempa made me wondering and I think that we should have a better way to track what exactly is installed by rosdep and we should be saving such thing as an artifact in base image. What do you think? If yes, we can create item and include it after this release.
Footnotes
-
As far as I tested, rosdep in base image does not install any ROS-related dependencies. ↩
355ca65
to
8cd6391
Compare
8cd6391
to
81f4ecc
Compare
Please let me know what is needed to get this approved. I think I need to add an issue number to each commit and squash some commits to clean up the history, is that correct? |
@Bckempa - I can make the small changes you suggested above when I add the issue number to the commits. I'll do this tonight |
8479383
to
8ee7b75
Compare
I squashed and added the issue to the commit messages. I also fixed the two issues that @Bckempa found in the README files I think this is ready for review |
Signed-off-by: Michael Jeronimo <[email protected]>
@mkhansenbot I think there's a level of detailed being retained here that is unnecessary. I sent you an email with two proposals (one more aggressive, one middle ground). Please check and confirm. Thanks! EDIT: Just documentation, my thought process is the following: I think the way to explain this PR is in two or three commits, keeping the detailed history is not necessary. Proposal one: Alternative middle ground: In the second proposal, other commits not listed there are just squashed with related commits (e.g., fixes to the README are squashed with the commit that introduces the README; it makes no sense to introduce it without fixes and fix it later). |
I'm fine with your second proposal |
8ee7b75
to
ebf3d7a
Compare
navigation2/README.md
Outdated
@@ -0,0 +1,47 @@ | |||
# Navigation2 Docker Image | |||
|
|||
The Navigation2 Docker image uses the Space ROS docker image (*openrobotics/spaceros:latest*) as its base image. The Navigation2 Dockerfile installs all of the prerequisite system dependencies to build Navigation2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this refer to osrf/spaceros:latest
instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Resolved.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, I made a mistake in my fix below 664665f. It should be space-ros
with a hyphen. My commit message spells it right but my actual commit spells it wrong.
ebf3d7a
to
b82ca0a
Compare
I'm waiting for this to build before I merge. |
This adds a Dockerfile to build navigation2 on top of Space ROS. It also adds corresponding
build.sh
andrun.sh
to build and run the container. Finally, it adds a build step to the workflow to build theosrf/space_nav2
imageInitial files were provided on a branch by @mjeronimo