Skip to content

feat(hangar_sim): enable fuse velocity_decay to prevent drift after nav2 stops#674

Open
bkanator wants to merge 2 commits into
mainfrom
feat/fuse-velocity-decay-hangar
Open

feat(hangar_sim): enable fuse velocity_decay to prevent drift after nav2 stops#674
bkanator wants to merge 2 commits into
mainfrom
feat/fuse-velocity-decay-hangar

Conversation

@bkanator
Copy link
Copy Markdown

@bkanator bkanator commented May 29, 2026

Summary

Enables `velocity_decay: 1.0` in `hangar_sim/config/fuse/fuse.yaml` to use the new parameter added in PickNikRobotics/fuse#34.

Fixes the fuse estimate drifting diagonally after a nav2 Objective completes and `platform_velocity_controller_nav2` deactivates. Tracked in PickNikRobotics/moveit_pro#18070.

Depends on PickNikRobotics/fuse#34 being merged and the apt package bumped in the Dockerfile first.

Claude agent checks

  • code-reviewer
  • test-runner
  • platform-architect-bot

@bkanator bkanator force-pushed the feat/fuse-velocity-decay-hangar branch from 259fb3b to cb84e1a Compare June 2, 2026 17:15
@bkanator bkanator marked this pull request as ready for review June 3, 2026 15:21
@bkanator bkanator requested a review from griswaldbrooks June 3, 2026 15:21
@bkanator bkanator force-pushed the feat/fuse-velocity-decay-hangar branch from caeffa1 to eade712 Compare June 3, 2026 15:22
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 3, 2026

MoveIt Pro Example WS - Objectives Integration Test Report

@bkanator bkanator force-pushed the feat/fuse-velocity-decay-hangar branch from eade712 to 6c5ba26 Compare June 4, 2026 14:40
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 4, 2026

MoveIt Pro Example WS - Objectives Integration Test Report

@bkanator bkanator force-pushed the feat/fuse-velocity-decay-hangar branch from 6c5ba26 to 21a9024 Compare June 4, 2026 19:20
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Jun 4, 2026

Review Change Stack

📝 Walkthrough

Summary by CodeRabbit

  • Chores
    • Updated motion model configuration to include a velocity decay parameter, providing enhanced control over velocity prediction behavior during periods of odometry inactivity.

Walkthrough

This PR introduces a new velocity_decay: 1.0 configuration parameter to the mobile base motion model in the fusion configuration. The parameter controls the exponential decay rate of predicted velocity toward zero when the odometry source becomes silent or unavailable.

Changes

Motion Model Velocity Decay Configuration

Layer / File(s) Summary
Velocity decay tuning parameter
src/hangar_sim/config/fuse/fuse.yaml
Added velocity_decay: 1.0 parameter under mobile_base_motion configuration to control exponential velocity decay behavior when odometry is unavailable, with comments describing the effect.
🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Description check ✅ Passed The pull request description clearly explains the change (enabling velocity_decay parameter), the problem it solves (fuse drift after nav2 stops), and its dependencies, all directly related to the changeset.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Human Review Check ✅ Passed PR adds velocity_decay parameter to hangar_sim fuse.yaml config only—low-risk simulation config change, not auth/billing/migrations/CI-CD/infra/API changes.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@src/hangar_sim/config/fuse/fuse.yaml`:
- Around line 22-26: The new velocity_decay parameter in fuse.yaml may not be
supported by the installed fuse library; verify that PickNikRobotics/fuse#34 has
been merged and released, then pin or bump the required fuse package version in
the Dockerfile and dependency manifests (package.xml / rosdep keys) so the
runtime installs the release that adds velocity_decay, and confirm the
fixed_lag_smoother_node actually reads/validates the velocity_decay parameter
(search for fixed_lag_smoother_node and velocity_decay in the codebase and
update the node or wrapper to handle the parameter if missing).
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 6858accb-009c-495f-a987-6c1239e76a56

📥 Commits

Reviewing files that changed from the base of the PR and between 6cc98a0 and 21a9024.

📒 Files selected for processing (1)
  • src/hangar_sim/config/fuse/fuse.yaml

Comment on lines +22 to +26
# Exponential velocity decay rate (1/s). Predicted velocity decays toward zero when the
# odometry source goes silent (e.g., after a nav2 controller deactivates), preventing
# indefinite drift. Set to 0.0 to disable. k=1.0 chosen so velocity is ~95% decayed
# within 3s — long enough to not affect normal driving, short enough to kill post-nav2 drift.
velocity_decay: 1.0
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major | 🏗️ Heavy lift

Verify that the fuse library version supports velocity_decay before merging.

The PR objectives state this depends on PickNikRobotics/fuse#34 being merged and the apt package being bumped in the Dockerfile. If the underlying fuse_models library doesn't yet support the velocity_decay parameter, this configuration will either:

  • Fail with a parameter validation error at node startup, or
  • Be silently ignored, leaving the drift issue unresolved

Before merging, confirm that:

  1. Add velocity_decay to Omnidirectional3D to prevent drift when odom goes silent fuse#34 has been merged and released
  2. The Dockerfile or dependency declarations (e.g., package.xml, rosdep keys) pin or require the updated fuse version
  3. The fixed_lag_smoother_node will validate and use this parameter
#!/bin/bash
# Description: Check for fuse library version requirements and velocity_decay parameter usage

# Check if Dockerfile specifies fuse version requirements
echo "=== Checking Dockerfile for fuse version ==="
fd -t f -e Dockerfile -x rg -n "fuse"

# Check package.xml files for fuse dependencies
echo -e "\n=== Checking package.xml for fuse dependencies ==="
fd -t f "package.xml" -x rg -n -A2 "fuse"

# Search for other references to velocity_decay in the codebase
echo -e "\n=== Searching for velocity_decay references ==="
rg -n "velocity_decay"
Is the velocity_decay parameter supported in the fuse ROS2 library, and in which version was it introduced?
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/hangar_sim/config/fuse/fuse.yaml` around lines 22 - 26, The new
velocity_decay parameter in fuse.yaml may not be supported by the installed fuse
library; verify that PickNikRobotics/fuse#34 has been merged and released, then
pin or bump the required fuse package version in the Dockerfile and dependency
manifests (package.xml / rosdep keys) so the runtime installs the release that
adds velocity_decay, and confirm the fixed_lag_smoother_node actually
reads/validates the velocity_decay parameter (search for fixed_lag_smoother_node
and velocity_decay in the codebase and update the node or wrapper to handle the
parameter if missing).

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 4, 2026

MoveIt Pro Example WS - Objectives Integration Test Report

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants