erl_active_mapping provides algorithms and agents for active exploration and mapping. The package includes a small,
reusable agent interface and a frontier-based 2D grid agent that integrates log-odd occupancy maps, environment / motion
models, and A* planning to generate exploration goals and paths.
- Templated
AgentBaseinterface for implementing exploration agents (include/erl_active_mapping/agent_base.hpp). - Frontier-based 2D grid agent that extracts frontiers from a log-odd occupancy map and plans to frontier goals (
include/erl_active_mapping/frontier_based_grid_2d.hpp). - YAML-configurable settings for frontier extraction, planning strategies and environment parameters.
- Integrations with other erl packages:
erl_geometry::LogOddMap2D,erl_env::Environment2D, anderl_path_planning::astar. - Python bindings (pybind11) for easy experimentation and scripting (
python/) (TODO).
include/erl_active_mapping/agent_base.hpp— Templated base class describing the agent API (Step, Plan, RandomPlan, ShouldReplan).include/erl_active_mapping/frontier_based_grid_2d.hpp— Frontier-based grid agent implementation, settings and helper types.
Create a workspace and add the package to src (example follows the standard CMake/ROS layout used across the erl_*
family):
cd <your_workspace>
mkdir -p src
# clone or copy erl_active_mapping into srcThis package is a normal CMake project (C++17). From your workspace root you can use a CMake-based build if you prefer:
cmake_minimum_required(VERSION 3.16)
project(<your_project_name>)
add_subdirectory(src/erl_cmake_tools)
add_subdirectory(src/erl_common)
add_subdirectory(src/erl_geometry)
add_subdirectory(src/erl_env)
add_subdirectory(src/erl_path_planning)
add_subdirectory(src/erl_active_mapping)Then build:
mkdir -p build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release
make -j$(nproc)The package includes ROS package metadata (package.xml) so it can be built with standard ROS build tools.
For ROS 1 (catkin):
cd <your_workspace>
source /opt/ros/<ros_distro>/setup.bash
catkin build erl_active_mapping
source devel/setup.bashFor ROS 2 (colcon):
cd <your_workspace>
source /opt/ros/<ros_distro>/setup.bash
colcon build --packages-up-to erl_active_mapping
source install/setup.bashThis package includes Python bindings (pybind11). There is a Python package layout under python/ and packaging
metadata (setup.py, pyproject.toml). To install into your active Python environment (pipenv, venv, or system):
cd <your_workspace>
cd src/erl_active_mapping
pip install . --user
# or using pipenv/venv: pip install .After installation, you should be able to import the module in Python:
import erl_active_mapping
# The bindings expose the frontier-based agent and helper utilities for scriptingRefer to python/binding/pybind11_erl_active_mapping.cpp and python/erl_active_mapping/__init__.py for the exposed
symbols and examples.
config/frontier_based_grid_2d.yaml— example YAML settings for the frontier-based grid agent.data/house_expo_room_1451.jsonanddata/house_expo_room_1451.csv— small example datasets used in experiments and tests.
Use the YAML config to customize planner behavior (plan strategy, replan strategy, goal tolerance, sampling parameters, etc.).
AgentBase<Dtype, Dim, Observation>: minimal interface for agents. Methods:Step(pose, observation): process a new observation at the given pose.Plan(state): generate a plan based on the current state.RandomPlan(state): generate a random plan based on the current state.ShouldReplan(state): determine if a replan is needed based on the current state.
frontier_based::AgentFrontierBasedGrid2D<Dtype, Observation>: implements frontier extraction from aLogOddMap2D, goal sampling, and A*-based planning to frontiers. ExposesSettingandFrontiertypes for configuration and inspection.
Contributions welcome. Please follow the repository code style (files include .clang-format) and add tests where
helpful. See CMakeLists.txt and Python packaging files for how targets and bindings are built.
This project is licensed under the MIT License — see the LICENSE file in the package for details.
