Repository navigation
Add fixed asset selection through variations - #1425
Closed
cvolkcvolk wants to merge 2 commits into
Closed
cvolkcvolk wants to merge 2 commits into
cvolkcvolk wants to merge 2 commits into
Conversation
Signed-off-by: Clemens Volk <cvolk@nvidia.com>
Signed-off-by: Clemens Volk <cvolk@nvidia.com>
This was referenced Oct 9, 2026
Collaborator
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add fixed asset selection through variations on a named
Object. Separate reusable native asset settings from the scene object that tasks and placement refer to.Why this change?
RigidObjectSetgives parallel environments different assets through a separate authoring path. Asset selection belongs alongside the other variations so experiments can enable it, configure sampling, and record the chosen asset for each episode.Build on the Object refactor in #1424, stacked on #1419. That refactor shares geometry and assignment support through
Objectand defers task scene configuration. This change adds selection, sampling, and recording on that foundation.What changes?
get_asset_definition()as a small adapter over existing rigid library constructors. It returns the registry name and a copy of the native spawn configuration. No new definition class or library migration is required.Objectreceive a default throughasset=..., or leave its asset unassigned until build time. The builder applies overrides and selection before placement. A missing asset is an error; the first candidate is never an implicit default.Objectindependent ofAssetSelectionVariation. The builder resolves selection, and the variation checks that its resolved source settings remain unchanged. Existing assignment validation checks the composed simulation configuration against placement.sample_per_environmentsetting.The adapter transfers native spawn settings, including scale and spawn physics settings. Scene poses, relations, variations, subclass behavior, and enclosing asset configuration settings stay with the scene object. Existing library constructors remain available.
Custom variations must accept the optional
VariationBuildContextargument in overridden build hooks. Custom runtime configs must setsample_per_environment=True; runtime preparation must not draw from the runtime sampler.Selection replay, build manifests, YAML candidate authoring, and deprecation of
RigidObjectSetremain future work. Enabled selection rejects recorded variation/placement replay, references into the selected target, and another enabled build-time variation on that target.Usage example
Before:
After:
Both examples alternate candidates across environments under the scene name
pickup. Episode records containcracker_boxorsugar_boxunderpickup.asset_selection. Another build requires fresh objects and variations.For an ordinary object, use
Object(name="pickup", asset=cracker_box_asset). Selection can also be attached to that object; when disabled, its default stays in use. Variations retain the existing disabled-by-default convention.Validation
206 targeted tests passed across asset definition lookup, selection, native physics and cloning, resets, geometry, placement, scene export, object sets, and variation recording. This includes regressions that reject source settings changed during the final configuration callback or before scene export.
The all-assets registry smoke test failed because the container lacks
pytetwild, an optional dependency needed to tetrahedralize its deformable cube. The remaining selected tests passed when continued separately. The full suite, camera phase, and subprocess phase were not rerun for this API revision.All repository pre-commit checks passed. Tests used the existing per-process Isaac Sim fast-exit option, disabled telemetry, and one OpenBLAS thread. The design document separates the implemented Python API from the proposed replay format.