Code Monkey home page Code Monkey logo

pothole-reporting-robot's Introduction

Summary of Solution

This repository contains my implementation of a pothole detector using the provided simple world map. The solution makes use of OpenCV to evaluate the pothole colours and thus their contours, as well as using the Depth sensing camera to determine to the position of a given pothole relative to the world frame. The robot navigates around the map using a set of waypoints and detects the potholes positions and size. Once the run is complete, a summary report will be produced, which can be found in the Pothole-Reporting-Robot/ros2_ws/summary_reports to be evaluated.

Guideline to run the code

This assumes that ros2 humble is already installed onto the system this will run on. This has also only been configured and tested on a native enviroments of ROS2.

Additional python packages to include

pip install reportlab
pip install matplotlib

Configuration

From a desired directory you will need to clone the limo_ros2 repository, as in the native instructions in https://github.com/LCAS/CMP9767_LIMO/wiki/Simulator-Setup. In a folder on the same level as the limo_ros2 installation, clone this Pothole-Reporting-Robot repository

git clone https://github.com/Olseda20/Pothole-Reporting-Robot.git

Your file structure should look like this. This is important due to how some of the automation of the pothole detection is being run.

.
├── limo_ros2
│   ├── src
│   ├── install
│   ├── build
│   └── ... 
└── Pothole-Reporting-Robot
    ├── README.md
    ├── ros2_ws
    └── ... 

Once both directories are available change into the Pothole-Reporting-Robot directory.

cd Pothole-Reporting-Robot

Ideally if the rviz2 config file could be loaded into rviz by default, this would be useful in seeing the markers of the pothole in realtime. However this information will be produced in the summary report.

From here all that needs to be run is the the shell script. This will start up

  1. Gazbo
  2. Rviz2
  3. Launch the my_robot_bringup launch file
  4. Begin running follow_waypoint to begin recording the pothole position

If zsh is installed on your system, this can be started by making sure it is executable and simply running the script

chmod +x run_pothole_detector.sh
./run_pothole_detector.sh

Otherwise use the bash variant

chmod +x run_pothole_detector_bash.sh
./run_pothole_detector_bash.sh

Now enjoy as the potholes are being detected.
Once this is complete, navigate to the directory Pothole-Reporting-Robot/ros2_ws/summary_reports to see the output of the detection.

A demo run can be seen here: https://www.youtube.com/watch?v=fvODO8_kK-I


To manually deploy the parts

If you would like to run the different sections independently, navigate to the Pothole-Reporting-Robot/ros2_ws directory and run: For every new terminal, please made sure all of the source setups files are being run. Note: please use the correct setup for your interpreter

source /opt/ros/humble/setup.zsh
source /usr/share/colcon_argcomplete/hook/colcon-argcomplete.zsh
colcon build
source ../../limo_ros2/install/setup.zsh
source install/setup.zsh

To start Gazebo:

ros2 launch limo_gazebosim limo_gazebo_diff.launch.py world:='../worlds/potholes_simple.world'

In a new terminal to start RViz:

ros2 launch limo_navigation limo_navigation.launch.py map:=../maps/simple_map.yaml params_file:=/home/krono/dev/RobotProgramming/Pothole-Reporting-Robot/params/nav2_params.yaml use_sim_time:=true;

In a new terminal to start the node for pothole detection

ros2 run my_robot_controller simple_pothole_detector

In a new terminal to start the node to publishing the pothole positions as markers in the '/odom' frame

ros2 run my_robot_controller pothole_mapper

In a new terminal to begin the waypoint following and report generation

ros2 run my_robot_controller pothole_reporter

pothole-reporting-robot's People

Contributors

omroali avatar

Stargazers

 avatar

Watchers

 avatar

pothole-reporting-robot's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.