P_EEMEF_DARC is an advanced robotics project focusing on autonomous navigation and collision avoidance using deep reinforcement learning. The main purpose is to provide a robust framework for TurtleBot3 to navigate complex environments autonomously.
Demo Video: Watch Here
These instructions will help you get a copy of the project up and running on your local machine for development and testing purposes.
Ensure you have the following software installed on your machine:
- Ubuntu 18.04
- ROS Melodic
- PyTorch (1.4)
- NumPy (1.16.6)
-
Activate your Python environment:
conda activate <environment_name> source activate <environment_name>
-
Install the required Python packages:
pip install -r requirements.txt
-
Install ROS Melodic and other dependencies:
sudo apt-get update sudo apt-get upgrade wget https://raw.githubusercontent.com/ROBOTIS-GIT/robotis_tools/master/install_ros_melodic.sh && chmod 755 ./install_ros_melodic.sh && bash ./install_ros_melodic.sh sudo apt-get install ros-melodic-joy ros-melodic-teleop-twist-joy ros-melodic-teleop-twist-keyboard ros-melodic-laser-proc ros-melodic-rgbd-launch ros-melodic-depthimage-to-laserscan ros-melodic-rosserial-arduino ros-melodic-rosserial-python ros-melodic-rosserial-server ros-melodic-rosserial-client ros-melodic-rosserial-msgs ros-melodic-amcl ros-melodic-map-server ros-melodic-move-base ros-melodic-urdf ros-melodic-xacro ros-melodic-compressed-image-transport ros-melodic-rqt-image-view ros-melodic-gmapping ros-melodic-navigation ros-melodic-interactive-markers
-
Clone the necessary repositories and compile the workspace:
cd ~/catkin_nav/src/ git clone https://github.com/ROBOTIS-GIT/turtlebot3_msgs.git git clone https://github.com/ROBOTIS-GIT/turtlebot3.git git clone https://github.com/hanlinniu/turtlebot3_ddpg_collision_avoidance.git cd ~/catkin_nav && catkin_make echo "export TURTLEBOT3_MODEL=waffle" >> ~/.bashrc source ~/.bashrc
To start the simulation in Gazebo, use the following commands to launch different environments:
1.1. Launch Corridor 1 World
roslaunch turtlebot_darc turtlebot3_empty_world.launch world_file:='/home/he/catkin_nav/src/turtlebot3_darc_nav/turtlebot_darc/world/3_corridor.world'
1.2. Launch Corridor 2 World
roslaunch turtlebot_darc turtlebot3_empty_world.launch world_file:='/home/he/catkin_nav/src/turtlebot3_darc_nav/turtlebot_darc/world/2_corridor.world'
roslaunch turtlebot_darc turtlebot3_empty_world.launch world_file:='/home/he/catkin_nav/src/turtlebot3_darc_nav/turtlebot_darc/world/record_maze.world'
3.1. Train and Play with DARC Using Human Data
-
Open the environment:
cd ~/catkin_nav/src/turtlebot3_darc_nav/turtlebot_nav/scripts/record_data
-
Open two terminals and run the following scripts:
python record_control.py python record_data.py
3.2. Training
-
Open the environment:
cd ~/catkin_nav/src/turtlebot3_darc_nav/turtlebot_nav/scripts
-
Open the terminal and run one of the following Python files:
python darc_turtlebot3_original_darc.py python p_darc_turtlebot3_original.py python turtlebot_turtlebot3_peemef_darc_env.py
nfhe