Skip to content

Commit

Permalink
ROS2 -> ROS 2
Browse files Browse the repository at this point in the history
  • Loading branch information
sea-bass committed Dec 13, 2022
1 parent e7e748d commit 09d25e9
Show file tree
Hide file tree
Showing 17 changed files with 34 additions and 34 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
# Always publish test results even when there are failures.
if: ${{ always() }}

# Testing with ROS2
# Testing with ROS 2
ros2-test:
strategy:
matrix:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
[![Pyrobosim Tests](https://github.com/sea-bass/pyrobosim/actions/workflows/actions.yml/badge.svg?branch=main)](https://github.com/sea-bass/pyrobosim/actions/workflows/actions.yml)
[![Documentation Status](https://readthedocs.org/projects/pyrobosim/badge/?version=latest)](https://pyrobosim.readthedocs.io/en/latest/?badge=latest)

ROS2 enabled 2D mobile robot simulator for behavior prototyping.
ROS 2 enabled 2D mobile robot simulator for behavior prototyping.

By Sebastian Castro, 2022

Expand Down
2 changes: 1 addition & 1 deletion docker/run_docker.bash
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Run docker container
#
# To get a specific ROS2 distro, specify the ROS_DISTRO environment variable as follows:
# To get a specific ROS 2 distro, specify the ROS_DISTRO environment variable as follows:
# ROS_DISTRO=humble ./run_docker.bash
#
# To run a specific command, you can enter additional arguments:
Expand Down
2 changes: 1 addition & 1 deletion docs/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
pyrobosim
=========

pyrobosim is a ROS2 enabled 2D mobile robot simulator for behavior prototyping.
pyrobosim is a ROS 2 enabled 2D mobile robot simulator for behavior prototyping.

.. raw:: html

Expand Down
12 changes: 6 additions & 6 deletions docs/source/setup.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ Setup

This package is being tested with:

* Python 3.8 in Ubuntu 20.04, optionally with ROS2 Foxy
* Python 3.10 in Ubuntu 22.04, optionally with ROS2 Humble
* Python 3.8 in Ubuntu 20.04, optionally with ROS 2 Foxy
* Python 3.10 in Ubuntu 22.04, optionally with ROS 2 Humble

Local Setup
-----------

If using ROS2, clone this repo in a valid `colcon workspace <https://docs.ros.org/en/foxy/Tutorials/Workspace/Creating-A-Workspace.html>`_.
If using ROS 2, clone this repo in a valid `colcon workspace <https://docs.ros.org/en/humble/Tutorials/Workspace/Creating-A-Workspace.html>`_.
Otherwise, if running standalone, clone it wherever you would like.

To set up your Python virtual environment, configure and run
Expand Down Expand Up @@ -41,7 +41,7 @@ As documented in the above script, I recommend making a bash function in your ``
source /path/to/pyrobosim/setup/source_pyrobosim.bash
}

If you plan to use ROS2, you can similarly create a bash function like this:
If you plan to use ROS 2, you can similarly create a bash function like this:

::

Expand All @@ -53,9 +53,9 @@ If you plan to use ROS2, you can similarly create a bash function like this:
Docker Setup
------------

We also provide Docker images compatible with ROS2 Foxy and Humble releases.
We also provide Docker images compatible with ROS 2 releases.

If you already have sourced ROS2 in your system (e.g., ``source /opt/ros/humble/setup.bash``),
If you already have sourced ROS 2 in your system (e.g., ``source /opt/ros/humble/setup.bash``),
then you should have a ``ROS_DISTRO`` environment variable set. Otherwise,

::
Expand Down
10 changes: 5 additions & 5 deletions docs/source/usage/basic_usage.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ click the **Navigate** button. Once at the destination, click **Pick**.

|
With ROS2
---------
With ROS 2
----------

First, build and setup the ``colcon`` workspace (or use one of our provided Docker containers).

Expand All @@ -41,7 +41,7 @@ First, build and setup the ``colcon`` workspace (or use one of our provided Dock
. install/local_setup.bash


You can run a ROS2 enabled demo and interact with the GUI:
You can run a ROS 2 enabled demo and interact with the GUI:

::

Expand All @@ -64,12 +64,12 @@ Or, you can run both of these nodes together using a provided launch file:
ros2 launch pyrobosim_ros demo_commands.launch.py mode:=action


The first command will start a world as a ROS2 node, and the second one will publish a plan (or set of actions) to the node.
The first command will start a world as a ROS 2 node, and the second one will publish a plan (or set of actions) to the node.

.. image:: ../media/pyrobosim_demo_ros.png
:align: center
:width: 600px
:alt: Basic ROS2 demo.
:alt: Basic ROS 2 demo.

|
Expand Down
2 changes: 1 addition & 1 deletion docs/source/usage/index.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Usage
=====
This package works with or without ROS2, and with or without a
This package works with or without ROS 2, and with or without a
PyQt5 based GUI for visualization.

Refer to the following pages for different types of usage guides.
Expand Down
8 changes: 4 additions & 4 deletions docs/source/usage/multirobot.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ Or you can use a sample multirobot world file:

|
With ROS2
---------
With ROS 2
----------

First, build and setup the ``colcon`` workspace (or use one of our provided Docker containers).

Expand All @@ -38,7 +38,7 @@ First, build and setup the ``colcon`` workspace (or use one of our provided Dock
. install/local_setup.bash


You can run a ROS2 enabled multirobot demo and interact with the GUI:
You can run a ROS 2 enabled multirobot demo and interact with the GUI:

::

Expand All @@ -62,6 +62,6 @@ The output should look as follows:
.. image:: ../media/pyrobosim_demo_multirobot_plan.png
:align: center
:width: 720px
:alt: pyrobosim multirobot demo with ROS2 executing multiple plans.
:alt: pyrobosim multirobot demo with ROS 2 executing multiple plans.

|
10 changes: 5 additions & 5 deletions docs/source/usage/tamp.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ If you did not already install PDDLStream, ensure you do so with this script, th

Examples
--------
Regardless of running PDDLStream standalone or using ROS2, we have included a set of examples
Regardless of running PDDLStream standalone or using ROS 2, we have included a set of examples
that gradually build up from simple, purely discrete planning, to a more complex integrated TAMP
demo with continuous action parameters.

Expand Down Expand Up @@ -44,8 +44,8 @@ You can try running a sample script as follows

|
With ROS2
---------
With ROS 2
----------

First, build and setup the ``colcon`` workspace (or use one of our provided Docker containers).

Expand All @@ -56,7 +56,7 @@ First, build and setup the ``colcon`` workspace (or use one of our provided Dock
. install/local_setup.bash


With ROS2, the idea is to separate out functionality into different *nodes*.
With ROS 2, the idea is to separate out functionality into different *nodes*.

To start a world and then a planner with a hard-coded goal specification:

Expand Down Expand Up @@ -85,6 +85,6 @@ The output should look as follows:
.. image:: ../media/pddlstream_demo_ros.png
:align: center
:width: 720px
:alt: PDDLStream demo with ROS2.
:alt: PDDLStream demo with ROS 2.

|
2 changes: 1 addition & 1 deletion pyrobosim/examples/demo.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,5 +117,5 @@ def parse_args():
else:
w = create_world_from_yaml(args.world_file)

# Start the program either as ROS2 node or standalone.
# Start the program either as ROS node or standalone.
start_gui(w, sys.argv)
2 changes: 1 addition & 1 deletion pyrobosim/pyrobosim/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
""" ROS2 enabled 2D mobile robot simulator for behavior prototyping. """
""" ROS 2 enabled 2D mobile robot simulator for behavior prototyping. """
2 changes: 1 addition & 1 deletion pyrobosim/pyrobosim/core/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
This module contains all the tools for world representation
(e.g. robots, rooms, locations, objects).
Additionally, tools for interfacing with ROS2, importing from
Additionally, tools for interfacing with ROS 2, importing from
YAML files, and exporting Gazebo worlds and occupancy grids reside here.
"""
4 changes: 2 additions & 2 deletions pyrobosim/pyrobosim/core/ros_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@


class WorldROSWrapper(Node):
""" ROS2 wrapper node for pyrobosim worlds. """
""" ROS 2 wrapper node for pyrobosim worlds. """
def __init__(self, world=None, name="pyrobosim",
num_threads=os.cpu_count(), state_pub_rate=0.1):
"""
Creates a ROS2 world wrapper node.
Creates a ROS 2 world wrapper node.
Given a node name (default is ``"pyrobosim"``), this node will:
* Subscribe to single actions on the ``pyrobosim/commanded_action`` topic.
Expand Down
2 changes: 1 addition & 1 deletion pyrobosim/pyrobosim/utils/general.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def get_data_folder():
:rtype: str
"""
try:
# If running as a ROS2 node, get the data folder from the package share directory.
# If running as a ROS 2 node, get the data folder from the package share directory.
from ament_index_python.packages import get_package_share_directory
data_folder = os.path.join(
get_package_share_directory("pyrobosim"), "data")
Expand Down
2 changes: 1 addition & 1 deletion pyrobosim/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def get_files_in_folder(directory):
url="https://github.com/sea-bass/pyrobosim",
author="Sebastian Castro",
author_email="sebas.a.castro@gmail.com",
description="ROS2 enabled 2D mobile robot simulator for behavior prototyping.",
description="ROS 2 enabled 2D mobile robot simulator for behavior prototyping.",
license="BSD",
install_requires=install_requires,
packages=find_packages(),
Expand Down
2 changes: 1 addition & 1 deletion pyrobosim_ros/examples/demo_pddl_planner.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env python3

"""
Test script showing how to use a PDDLStream planner as a ROS2 node.
Test script showing how to use a PDDLStream planner as a ROS 2 node.
"""

import os
Expand Down
2 changes: 1 addition & 1 deletion pyrobosim_ros/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<package format="3">
<name>pyrobosim_ros</name>
<version>0.0.0</version>
<description>ROS2 wrapper around pyrobosim.</description>
<description>ROS 2 wrapper around pyrobosim.</description>
<maintainer email="sebas.a.castro@gmail.com">Sebastian Castro</maintainer>
<license>BSD</license>

Expand Down

0 comments on commit 09d25e9

Please sign in to comment.