Skip to main content

nav_explore_eval

CI ROS 2 License

How good was that exploration run? Score any ROS 2 exploration against a ground-truth map: coverage, wall accuracy, and time to 25 / 50 / 75 / 90 %. It only watches /map and /odom, so it works with any explorer, any SLAM and any robot.

Coverage of the explorable area growing over a 7-minute run, with wall F1 and false-free live

A real 7-minute run: explore:=true on a Gazebo maze, scored against the exact ground truth built from the world file. Data: docs/demo_run.json, renderer: docs/make_demo_gif.py.

Built alongside rosnav, a ROS 2 Nav2 stack with SLAM, frontier exploration and multi-robot fleets, and run on its Gazebo maze sim.

Install

pip install nav_explore_eval      # latest main instead: pip install git+https://github.com/darshmenon/nav_explore_eval

record and reading bags need a sourced ROS 2 environment. A pip install puts the nav_explore_eval command on your PATH; run it directly. The ros2 run form below needs the colcon build.

Quick start

# 1. exact ground truth from your Gazebo world (no SLAM run needed); --seed = robot spawn
ros2 run nav_explore_eval nav_explore_eval truth-from-world maze.world --out maze_truth --seed 0 0

# 2. start your explorer as usual, then score it live (writes a JSON report at the end)
ros2 run nav_explore_eval nav_explore_eval record --truth maze_truth.yaml --label my_explorer --out run.json --align

# 3. compare runs side by side, optional chart
ros2 run nav_explore_eval nav_explore_eval compare run.json other.json --png compare.png

# or score a map you already saved
ros2 run nav_explore_eval nav_explore_eval score map.yaml maze_truth.yaml --align

Real output of the run above:

       label  cov%   f1%  leak%  path_m  t25%(s)  t50%(s)  t75%(s)  t90%(s)
builtin_maze  43.8  64.1    0.0    15.9      158        -        -        -

What it measures

Metric Meaning
coverage share of the explorable free space (reachable from the spawn point) the map has marked free
wall F1 precision and recall of wall cells within --tol metres (default 0.10)
leak (false-free) share of real wall cells the map shows as free space, which is the dangerous error
t25 … t90 interpolated time to reach each coverage level (- = never reached)
path_m distance driven, from /odom
  • Auto-align (--align): a SLAM map starts at the robot, not at the truth map's origin, so the tool finds the translation between the two frames by FFT correlation of the walls (the run above found a 1.5 m, 0.9 m offset).
  • Ground truth from the world file: rasterises the box and cylinder collisions that cross the lidar height (--z) and counts only space reachable from --seed as explorable, so sealed-off rooms and the outside never count against you.

More commands

# score a recorded rosbag2 offline (no live sim needed)
nav_explore_eval bag my_bag/ --truth maze_truth.yaml --label run1 --out run1.json --align

# repeat trials (restart the explorer before each), then mean +/- std grouped by label
nav_explore_eval record --truth maze_truth.yaml --label A --out results/A.json --align --repeat 5 --between ./restart.sh
nav_explore_eval stats results/

# one-file HTML report; add --map/--truth for the map-vs-truth overlay (leaks in red)
nav_explore_eval report results/ --out report.html --map slam_map.yaml --truth maze_truth.yaml

# multi-robot: merged coverage, each robot's unique share, overlap
nav_explore_eval record --robots robot1,robot2 --truth maze_truth.yaml --align
nav_explore_eval score-multi r1.yaml r2.yaml --truth maze_truth.yaml

# localisation error: compare /odom with a ground-truth Odometry topic (works for record and bag)
nav_explore_eval record --truth maze_truth.yaml --gt-odom /ground_truth/odom --align
nav_explore_eval bag my_bag/ --truth maze_truth.yaml --gt-odom /ground_truth/odom

# rotated SLAM frame: also search yaw
nav_explore_eval score map.yaml maze_truth.yaml --rotate

Extra run metrics: covered_area_m2 and efficiency_m2_per_m (area explored per metre driven). See LEADERBOARD.md to compare runs; add yours as results/<name>.json in a pull request (nav_explore_eval validate checks it). Combining with fault injection: docs/integrations.md.

Limits

  • Yaw search is a coarse grid (--max-yaw, 1 degree steps) about the world origin, and it multiplies align time.
  • truth-from-world reads boxes, cylinders and meshes (as bounding boxes, so concave meshes are filled in); heightmaps and <polyline> are skipped with a warning.
  • Two SLAM runs of the same world can score low on wall F1 even when they look alike. Raise --tol when comparing runs against each other, and prefer a world-file truth.
  • Multi-robot assumes all maps share one frame (each is aligned to the truth separately).
  • Localisation error (ATE) pairs poses by nearest time within 0.25 s and rigidly fits the trajectory first, so it measures drift, not frame offset. It also reports translational RPE over 1 m of path (rpe_rmse_m), a frame-independent local drift measure. It compares /odom to your ground-truth topic.

Roadmap

  • true polygon footprints for meshes
  • more entries on the leaderboard

Build: colcon build --packages-select nav_explore_eval. Tests: python3 -m pytest test (the live record tests run when ROS 2 is sourced). Part of a set with nav2_doctor and nav2_fault_inject.

Metadata

Release files for nav-explore-eval 0.3.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nav-explore-eval 0.3.3
File Size Uploaded Provenance Actions
nav_explore_eval-0.3.3.tar.gz 37.6 kB With provenance Details for nav_explore_eval-0.3.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for nav-explore-eval 0.3.3
File Interpreter ABI Platform Actions
nav_explore_eval-0.3.3-py3-none-any.whl Python 3 none any Details for nav_explore_eval-0.3.3-py3-none-any.whl

Total release size: 67.8 kB

Security for nav-explore-eval 0.3.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for nav_explore_eval-0.3.3.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 29, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.3.3 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page