A ROS package, relying on the RGB-D camera technology, developed for a course regarding the Cybathlon contest's sidewalk challenge.
Its purpose is to identify obstacles to avoid, within a certain margin of error, and isolate the optimal direction for a visually impared person to follow.
Tested and reviewed under ROS-noetic and Ubuntu 20.04, this package, unaltered, depends on the use of an Astra Pro camera made by Orbbec as well as its ROS1 package ros_astra_camera
.
You will also need the darknet_ros
package.
Make sure that the two previously mentionned dependencies are downloaded in your catkin workspace.
- Once everything is checked and working, clone the latest version of the repository in the
src
folder of your workspace and build the newly added packages.
cd catkin_ws/src
git clone https://github.com/SkyaX/sidewalk.git
cd ..
catkin_make
The pre_sidewalk.launch
file starts the launch files from the two previously mentionned packages.
Notice that you need to adjust the followings in order to make it work with the Astra Pro camera as well as any other camera/package pair :
- The included
astra_pro.launch
used by our particular model :
<!-- includes RGB-D launch file -->
<include file = "$(find astra_camera)/launch/astra_pro.launch"/>
- The included
darknet_ros.launch
altered as follows :
<!-- includes darknet launch file -->
<include file = "$(find darknet_ros)/launch/darknet_ros.launch"/>
The 6th line may be adjusted depending on the topic in which the RGB image from your camera is published.
- Note that we used yoloV7-tiny, which does not come ready with
darknet_ros
. After downloading thedarknet_ros
package, you can simply add theyolov7.yaml
file in thedarknet_ros/config
folder. Then change the 14th line of the previously mentioned file fromyolov3.yaml
->yolov7.yaml
. Finally, you can add the yolov7-tiny.weights & yolov7-tiny.cfg in thedarknet_ros/yolo_network_config/weights
&darknet_ros/yolo_network_config/cfg
folders, respectively.
Here is an overview of the system's organisation :
- Firstly, make sure that the Subscribers in the file
trajectoire_final.py
are correctly created. They should be given the correct topic depending on the package you use for your camera, as follows :
cam_img_sub = message_filters.Subscriber('/camera/color/image_raw', Image)
depth_img_sub = message_filters.Subscriber('/camera/depth/image_raw', Image)
The library message_filters
is used to assure the correct synchronization between the depth and RGB images.
- Start by launching the
pre_sidewalk.launch
file :
roslaunch sidewalk pre_sidewalk.launch
- You can then launch the main file :
roslaunch sidewalk opti_sidewalk.launch
The different OpenCV outputs :
Marine Ducrot, Matthieu Lacheny and Axel Lansiaux