AGRIBOT requires a full ROS Melodic installation with Gazebo 9 and several sensor simulation plugins to run the autonomous navigation stack. On top of the ROS layer, the CNN crop-weed classification pipeline depends on a set of Python packages built around TensorFlow 1.x and Keras. This guide walks through every installation step in order, from the base OS packages to building the catkin workspace.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/Dhruv2012/Autonomous-Farm-Robot/llms.txt
Use this file to discover all available pages before exploring further.
System Requirements
Before installing, confirm your environment meets these minimum specifications:Operating System
Ubuntu 18.04 LTS with ROS Melodic (recommended), or Ubuntu 16.04 with ROS Kinetic
Memory
At least 8 GB RAM. An NVIDIA GPU is recommended for real-time Bonnet CNN inference (tested on NVIDIA 940 MX, avg. 2.5 fps)
Python
Python 3.6 or later (required by the
autonomous_drive and classification packages)Simulator
Gazebo 9 or later (included with
ros-melodic-desktop-full)ROS and Gazebo Installation
Install ROS Melodic from the official ROS package repository. Thedesktop-full variant includes Gazebo 9, RViz, and all standard ROS tools in a single install.
roscore launches without errors before proceeding.
ROS Dependencies
AGRIBOT relies on several ROS packages beyond the desktop-full bundle. Install them all with a singleapt-get chain:
| Package | Role in AGRIBOT |
|---|---|
hector-gazebo-plugins | Simulates GPS (libhector_gazebo_ros_gps.so), IMU (libhector_gazebo_ros_imu.so), and magnetometer (libhector_gazebo_ros_magnetic.so) on the robot model |
gazebo-ros-control | Bridges Gazebo’s physics engine with ros_control effort controllers |
ros-control / ros-controllers | Provides PID effort controllers for the four wheel joints |
teleop-tools | Enables keyboard and joystick teleoperation for manual testing |
move-base | Action server used by AutonomusDriveAction.py for waypoint patrol navigation |
mapviz / mapviz-plugins | GPS trajectory visualization alongside the Gazebo simulation |
multires-image | Required by the Mapviz tile-map plugin for satellite imagery overlays |
Python Dependencies for Classification
The crop-weed classification pipeline uses a Bonnet CNN architecture trained on the CWFID and Bonn sugar beet datasets. Install all Python dependencies withpip3:
The classification code in
Crop_Weed_Classification/model.py was written for TensorFlow 1.x and Keras 2.x. The pip-installable version that matches the original development environment is tensorflow==1.14. Upgrading to TensorFlow 2.x will introduce breaking API changes — particularly around keras.backend, session handling, and model loading. Test compatibility thoroughly before upgrading your environment.Build the Catkin Workspace
With all system and Python dependencies in place, build the AGRIBOT catkin workspace:catkin_make compiles the following packages in dependency order:
agribot— top-level meta-packageagribot_description— URDF/xacro models, Gazebo worlds, maps, and launch filesagribot_control— PID controller configuration and spawner launch fileautonomous_drive— GPS conversion, sensor fusion, and autonomous drive Python nodes
Verify Installation
Confirm that ROS can locate all three core AGRIBOT packages:catkin_make in agribot_ws and confirm that the workspace devel/setup.bash has been sourced in the current shell.