Kompass Core

Kompass Core is a fast, GPU powered motion planning and control package for robot navigation. The package contains C++ implementation for core algorithms along with Python wrappers. It also implements third party integrations with OMPL and FCL. The Kompass philosophy is to be blazzingly fast and highly reliable, by implementing parallelized algorithms which are agnostic to underlying hardware. Thus Kompass Core can be run on CPUs, GPUs, NPUs or FPGAs from a wide variety of vendors, making it easy for robot manufacturers to switch underlying compute architecture.
This package is developed to be used with Kompass for creating navigation stacks in ROS2. For detailed usage documentation, check Kompass docs.
Installation
Install with GPU Support (Recommended)
To install kompass-core with GPU support, on any Ubuntu (including Jetpack) based machine, you can simply run the following:
curl https://raw.githubusercontent.com/automatika-robotics/kompass-core/refs/heads/main/build_dependencies/install_gpu.sh | bash
This script will install all relevant dependencies, including AdaptiveCPP and install the latest version of kompass-core from source. It is good practice to read the script first.
Installing with pip
On Ubuntu versions >= 22.04, install dependencies by running the following:
sudo apt-get install libompl-dev libfcl-dev libpcl-dev
Then install kompass-core as follows:
Wheels are available on Pypi for linux x86_64 and aarch64 architectures. Please note that the version available on Pypi does not support GPU acceleration yet.
Installation Contents
The following three packages will become available once kompass-core is installed.
kompass_core
: The main Python API containing all the wrappers and utilities for motion planning and control for navigation in 2D spaces.kompass_cpp
: Pybind11 python bindings for Kompass core C++ library containing the algorithms implementation for path tracking and motion control.ompl
: Bespoke Pybind11 python bindings for the Open Motion Planning Library (OMPL).
Testing
Run Planning Test
cd tests
python3 test_ompl.py
To test path planning using OMPL bindings a reference planning problem is provided using Turtlebot3 Waffle map and fixed start and end position. The test will simulate the planning problem for all geometric planners for the number of desired repetitions to get average values.
Run Controllers Test
cd tests
python3 test_controllers.py
The test will simulate path tracking using a reference global path. The results plot for each available controller will be generated in tests/resources/control
Usage Example
from kompass_core.control import DVZ
from kompass_core.models import (
AngularCtrlLimits,
LinearCtrlLimits,
Robot,
RobotCtrlLimits,
RobotGeometry,
RobotType,
)
from nav_msgs.msg import Path
my_robot = Robot(
robot_type=RobotType.ACKERMANN,
geometry_type=RobotGeometry.Type.CYLINDER,
geometry_params=np.array([0.1, 0.4]),
)
robot_ctr_limits = RobotCtrlLimits(
vx_limits=LinearCtrlLimits(max_vel=1.0, max_acc=5.0, max_decel=10.0),
omega_limits=AngularCtrlLimits(
max_vel=2.0, max_acc=3.0, max_decel=3.0, max_steer=np.pi
),
)
control_time_step = 0.1
dvz = DVZ(
robot=my_robot,
ctrl_limits=robot_ctr_limits,
control_time_step=control_time_step,
)
global_path : Path = Path()
dvz.set_path(global_path)
laser_scan = LaserScanData()
dvz.loop_step(current_state=robot.state, laser_scan=laser_scan)
Copyright
The code in this distribution is Copyright (c) 2024 Automatika Robotics unless explicitly indicated otherwise.
Kompass Core is made available under the MIT license. Details can be found in the LICENSE file.
Contributions
Kompass Core has been developed in collaboration between Automatika Robotics and Inria. Contributions from the community are most welcome.