Skip to content

Remove the is_homogeneous helper from isaaclab core#5667

Merged
huidongc merged 1 commit into
isaac-sim:developfrom
huidongc:remove_homogeneous_helper
May 18, 2026
Merged

Remove the is_homogeneous helper from isaaclab core#5667
huidongc merged 1 commit into
isaac-sim:developfrom
huidongc:remove_homogeneous_helper

Conversation

@huidongc
Copy link
Copy Markdown
Collaborator

@huidongc huidongc commented May 18, 2026

Description

Removed is_homogeneous() helper for clone plan from the IsaacLab core.

Type of change

  • Internal refactoring (non-user-visible behavior change)

Checklist

  • I have read and understood the contribution guidelines
  • I have run the pre-commit checks with ./isaaclab.sh --format
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • I have updated the changelog and the corresponding version in the extension's config/extension.toml file
  • I have added my name to the CONTRIBUTORS.md or my name already exists there

@github-actions github-actions Bot added the isaac-lab Related to Isaac Lab team label May 18, 2026
@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented May 18, 2026

Greptile Summary

This PR removes the is_homogeneous helper from isaaclab.cloner.cloner_utils and inlines its one-liner logic (clone_plan.clone_mask.all().item()) directly at its single call site in OVRTXRenderer. No other callers exist in the codebase.

  • cloner_utils.py: The is_homogeneous function (15 lines) is deleted entirely; the inlined expression is functionally identical to the original implementation.
  • ovrtx_renderer.py: The import is removed and the guard condition is updated to call clone_plan.clone_mask.all().item() inline.
  • Changelogs: A removal fragment is added for isaaclab and a .skip marker for isaaclab_ov (internal change, no public API impact on that extension).

Confidence Score: 5/5

Safe to merge — the removed function had exactly one caller and the inlined expression is byte-for-byte equivalent in behavior.

The only call site has been updated to inline the same one-liner that the removed helper wrapped. A codebase-wide search confirms no remaining references to is_homogeneous outside the changelog files. The logic in ovrtx_renderer.py is unchanged in effect.

No files require special attention.

Important Files Changed

Filename Overview
source/isaaclab/isaaclab/cloner/cloner_utils.py Removes the is_homogeneous helper function; no other callers remain in the codebase.
source/isaaclab_ov/isaaclab_ov/renderers/ovrtx_renderer.py Removes the import of is_homogeneous and inlines the equivalent expression clone_plan.clone_mask.all().item() directly in the guard condition.
source/isaaclab/changelog.d/huidongc-remove-homogeneous-helper.rst Changelog fragment documenting the removal of is_homogeneous.
source/isaaclab_ov/changelog.d/huidongc-remove-homogeneous-helper.skip Changelog skip marker for the isaaclab_ov extension, noting this is an internal refactor with no user-facing API change.

Sequence Diagram

sequenceDiagram
    participant OVRTXRenderer
    participant SimulationContext
    participant ClonePlan

    OVRTXRenderer->>SimulationContext: get_clone_plan()
    SimulationContext-->>OVRTXRenderer: clone_plan (or None)
    OVRTXRenderer->>ClonePlan: clone_plan.clone_mask.all().item()
    Note over OVRTXRenderer,ClonePlan: Previously delegated to is_homogeneous(clone_plan)
    ClonePlan-->>OVRTXRenderer: "bool (True = homogeneous)"
    alt heterogeneous (False)
        OVRTXRenderer->>OVRTXRenderer: log warning and disable OVRTX cloning
    else homogeneous (True)
        OVRTXRenderer->>OVRTXRenderer: proceed with OVRTX cloning
    end
Loading

Reviews (1): Last reviewed commit: "Remove the `is_homogeneous` helper from ..." | Re-trigger Greptile

Copy link
Copy Markdown

@isaaclab-review-bot isaaclab-review-bot Bot left a comment

Choose a reason for hiding this comment

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

🤖 Isaac Lab Review Bot — PR #5667

Summary

This PR removes the is_homogeneous() helper function from isaaclab.cloner.cloner_utils and inlines its logic at the single call site in OVRTXRenderer.

✅ Strengths

1. Clean Removal

  • The function was trivial (single line: return bool(clone_plan.clone_mask.all().item()))
  • Only one caller existed, and the inlined replacement is equally readable
  • Properly removes the import statement from ovrtx_renderer.py

2. Documentation

  • Changelog entry added for isaaclab noting the removal
  • Skip file added for isaaclab_ov explaining no user-facing API change
  • PR description accurately describes the change

3. Minimal Scope

  • 4 files, clean diff
  • No behavioral changes — functionally identical

⚠️ Minor Observations

1. Breaking Change Classification
The PR is marked as "Bug fix" but this is actually a breaking change if is_homogeneous was part of the public API (importable by users). Since the module uses lazy_export(), the function was likely accessible via from isaaclab.cloner import is_homogeneous. Users who imported this function will see an ImportError after upgrading.

Consider:

  • Marking this as a breaking change in the checklist/labels if external callers are possible
  • Or confirming this was always an internal implementation detail

2. Checklist Items
Several checklist items are unchecked (pre-commit, docs, warnings, tests, changelog version bump). The changelog fragment is present which is good, but please ensure pre-commit passes.

📋 Verdict

LGTM with minor consideration — The removal is clean and the inlined code is simple. Just verify whether this constitutes a breaking change for the release notes.


🤖 Automated review by Isaac Lab Review Bot

@huidongc huidongc requested a review from ooctipus May 18, 2026 02:45
@huidongc huidongc merged commit 5d69131 into isaac-sim:develop May 18, 2026
64 of 65 checks passed
@huidongc huidongc deleted the remove_homogeneous_helper branch May 18, 2026 04:34
matthewtrepte pushed a commit to matthewtrepte/IsaacLab that referenced this pull request May 18, 2026
# Description

Removed `is_homogeneous()` helper for clone plan from the IsaacLab core.

## Type of change

- Internal refactoring (non-user-visible behavior change)

## Checklist

- [x] I have read and understood the [contribution
guidelines](https://isaac-sim.github.io/IsaacLab/main/source/refs/contributing.html)
- [x] I have run the [`pre-commit` checks](https://pre-commit.com/) with
`./isaaclab.sh --format`
- [x] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [x] I have added tests that prove my fix is effective or that my
feature works
- [x] I have updated the changelog and the corresponding version in the
extension's `config/extension.toml` file
- [x] I have added my name to the `CONTRIBUTORS.md` or my name already
exists there

<!--
As you go through the checklist above, you can mark something as done by
putting an x character in it

For example,
- [x] I have done this task
- [ ] I have not done this task
-->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

isaac-lab Related to Isaac Lab team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants