localization-recovery

Detect and recover from AMCL localization failures via relocalization services.

18|2|Updated Apr 20, 2026
One-click install
npx skills add https://github.com/wimblerobotics/ros2-copilot-skills --skill localization-recovery
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: localization-recovery
Source: https://github.com/wimblerobotics/ros2-copilot-skills/tree/main/localization-recovery
Command: npx skills add https://github.com/wimblerobotics/ros2-copilot-skills --skill localization-recovery

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Localization failures in AMCL can cause pose jumps, map-odom inconsistencies, and navigation breakdowns. This Skill provides strategies to detect degradation, perform global relocalization, and recover the robot's pose to re-establish accurate localization.

Core Features & Use Cases

  • Global relocalization via the /reinitialize_global_localization service and particle re-seeding to re-converge on the map.
  • Manual initial pose correction using RViz' 2D Pose Estimate or by publishing to /initialpose for immediate pose reset.
  • Automated recovery workflows through covariance monitoring of /amcl_pose, optional particle-count tuning, and BT-based integration for safe, repeatable recovery.
  • Pose persistence across reboots to avoid cold-start localization when the robot hasn't moved.

Quick Start

Trigger global relocalization when AMCL covariance indicates high uncertainty, then verify convergence by moving the robot to collect diverse scans.

Frequently Asked Questions about localization-recovery

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I recover AMCL localization when pose jumps and navigation break down in ROS 2?

To recover AMCL localization when navigation breaks down, trigger global relocalization via the /reinitialize_global_localization service, monitor pose covariance, or manually reset the pose using RViz 2D Pose Estimate.

What causes AMCL to diverge and require global relocalization in ROS 2?

AMCL divergence is detected by monitoring high covariance in /amcl_pose, which indicates pose uncertainty. This degradation causes map-odom inconsistencies, requiring global relocalization or particle re-seeding to re-converge on the map.

How do I automate AMCL recovery workflows using ROS 2 behavior trees?

Automate AMCL recovery by integrating behavior-tree workflows that monitor /amcl_pose covariance and trigger service-based relocalization. This provides safe, repeatable recovery when localization failures occur.

Can I persist robot pose across reboots to avoid cold-start localization issues?

Yes, pose persistence across reboots avoids cold-start localization when the robot has not moved. This prevents initial localization failures by retaining the last known accurate pose instead of relying on default startup.

How do I manually reset AMCL initial pose using RViz when localization fails?

Manually reset AMCL initial pose using RViz' 2D Pose Estimate tool or by publishing directly to the /initialpose topic. This provides an immediate pose reset when automated global relocalization is insufficient.

When should I tune AMCL particle count for better localization robustness?

Tune AMCL particle count when covariance monitoring indicates persistent high uncertainty during recovery. Optional particle-count tuning helps the filter re-converge and maintain robust localization during global relocalization procedures.