Skip to content

Conversation

@MahimanaGIT
Copy link

@MahimanaGIT MahimanaGIT commented Oct 31, 2025

What this does

Noticed a critical bug in the policy migration which introduced severe regressions in policy performance.
When the camera name of the robot contains _, line 112 feature_name = ".".join(parts[:-1]).replace("_", ".") in migrate_policy_normalization.py used to convert it every _ to .. Due to which the normalize_processor while normalizing the input images won't be able to find the camera key and return the tensor without normalization at line 307 in normalize_processor.py during policy execution.

Fix:

  1. Added _ handling when there are multiple parts to the feature name in migrate_policy_normalization.py.
  2. Updated normalize_processor.py to raise error if policy is missing keys and updated its test.

How it was tested

  • Updated test_quantile_with_missing_stats in test_normalize_processor.py

How to checkout & try? (for the reviewer)

Provide a simple way for the reviewer to try out your changes.

  • pytest test/test_normalize_processor.py
  • Test the policy migration for a robot with camera having underscore _ in it.

@MahimanaGIT MahimanaGIT changed the title fix(migrate_policy_normalization): Fixes . replacement of _ in policy… Fix policy normalization migration keys Oct 31, 2025
@MahimanaGIT MahimanaGIT changed the title Fix policy normalization migration keys 🐛 Fix policy normalization migration keys Oct 31, 2025
@MahimanaGIT
Copy link
Author

@AdilZouitine can you be the primary reviewer of this MR as you were the lead on normalization migration and missing key handling in normalization processing.

@MahimanaGIT MahimanaGIT changed the title 🐛 Fix policy normalization migration keys fix policy normalization migration keys Oct 31, 2025
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.

1 participant