Omniverse Usd Performance Tuning
NVIDIAOfficialCreated by NVIDIA Omniverse
- Skill
- Workflow
- Software development
- Apache-2.0
- Medium risk
- Has scripts
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
This skill provides a structured workflow for diagnosing and optimizing USD stages. It focuses on improving performance metrics like load times, memory footprint, and frame rates by identifying and optimizing unique asset definitions, reusing shared definitions, and pruning unnecessary data. The process emphasizes preserving original asset boundaries, animation, and interface requirements, ensuring that downstream applications remain functional after optimization.
What it does
- Inspects USD stages to identify performance bottlenecks and structural inefficiencies.
- Classifies assets into atomic, package, or aggregate structures to guide optimization.
- Performs native USD optimization operations on disjoint scopes.
- Publishes semantic libraries to enable efficient asset reuse.
- Validates composition, ownership, and interface accessibility of the optimized output.
- Profiles the final output against the original baseline to report measured improvements.
When to use it
- When a USD stage suffers from slow loading times or high memory consumption.
- When rendering performance (FPS) needs improvement in a production environment.
- Before finalizing a USD assembly for downstream consumption.
- When you need to standardize asset structures according to factory-level guidelines.
Advantages
- Maintains asset boundaries and critical metadata during optimization.
- Reduces scene complexity through intelligent reuse of shared definitions.
- Provides verifiable reports on performance gains and composition integrity.
- Supports large-scale scene optimization by processing independent definition scopes.
Usage examples
- “Inspect the USD stage at /data/factory.usdc for performance issues and prepare a review workspace.”
- The agent initializes the workspace, runs the inspection script, and provides a summary of candidates for optimization.
- “Submit the optimization decisions for the factory stage based on the generated JSON.”
- The agent processes the boundary decisions, executes the optimization operations, and generates the final optimized USD assembly.
Install
Download the skill as a ZIP:
https://mp-staging.autogineer.com/agent-skills/nvidia/omniverse-usd-performance-tuning/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip omniverse-usd-performance-tuning.zip -d .agents/skills
Documentation by NVIDIA Omniverse
Omniverse USD Performance Tuning
Purpose
Improve loading, memory use or rendering for the requested workload. Preserve the prim paths, appearance, placement and behavior required by downstream applications. Follow the component/subcomponent model in NVIDIA's Factory-Level USD Structuring guide. Apply the relevant parts of that model; a static asset does not need new animation or physics.
Inputs
Required: the source USD stage. When no workload is specified, use factory layout planning and visualization and record that assumption in the request/report. Explicit workload and preservation requirements take precedence. Optional: an output workspace, preservation requirements, physical error budget, existing library indexes and recorded runtime evidence. Use values from the current user request; reuse recorded values only while they remain applicable. Follow setup when no output path is supplied.
Prerequisites
Verify the selected runtime and required capabilities using setup. Keep its preflight record with the run; installation and remote access are conditional steps described there.
Instructions
Inspect. Establish the workload, preservation requirements and output workspace. Set up progress and dashboard access before assessment. Verify setup and inspect the selected source configuration.
Judge boundaries. Review equipment, service-system sections and architectural elements in the selected configuration, including animation and interiors. Record owners, editable interfaces, equipment categories and optional families using boundary guidance.
Classify and author. Classify accepted assets children before parents. Capture or reuse the original profile before authoring. Prepare reusable definitions, materials and occurrence opinions using asset authoring.
Optimize unique definitions. Run supported native operations concurrently on disjoint scopes with the recorded physical budget.
Publish semantic libraries. Use one writer per category layer and remap consumer references.
Check composition. Check authored ownership, references, bindings, placement, animation and interface accessibility through the written-output checks.
Profile and report. Compare the final consumer with the original baseline under comparable conditions and report measured benefits, completion and operations by asset definition.
sequenceDiagram
participant A as Agent
participant T as USD tools
participant W as Definition workers
participant L as Library publisher
participant D as Read-only progress dashboard
Note over A,L: One compact progress state also renders text progress
T-->>D: Recorded phase, assessment rounds, counters and decision reasons
A->>T: Inspect original selected configuration
T->>T: Collect cached child-to-parent summaries and repetition nominations
T->>T: Load supplied indexes once and batch authored product clues
T-->>A: Product review groups, member context, animation and reuse evidence
loop Until boundaries and interiors are reviewed
A->>A: Select asset boundaries, then identify required internal prims and properties
A->>T: Submit boundary decisions with reviewed scope, required edits, category and optional family
T->>T: Reuse unchanged source evidence, recompute boundary-dependent results
opt Geometry ownership requires reconstruction
T->>T: Regroup or native split, remap paths and reassess affected regions
end
T-->>A: Remaining candidates and member exceptions
end
T->>T: Classify selected child assets before parent assets, confirm reuse
T->>T: Capture or reuse original baseline profile
T->>T: Confirm accepted product identities from source and supplied indexes; reconcile complete parent-child groups
T->>T: Skip worker inputs for confirmed groups; author remaining materials, editable prims and occurrence overrides
T->>T: Determine merge groups on prepared interiors; preserve selected child assets and required prims
T->>W: Read-only input USD layers for existing-library matching
par Independent preparation jobs
W->>W: Confirm remaining product, exact source or authorized normalized reuse; preserve occurrence placement
W->>W: Consolidate accepted product or compatible exact/normalized leaf inputs; retain every occurrence
end
W-->>T: Confirmed library hits and definitions requiring optimization
T->>W: Owned geometry prim paths in read-only input layers
par Independent definition scopes
W->>W: Remove small meshes when authorized; apply asset representation: reserve merge inputs or fit analytic prims; reduce, merge (native clustering if required), prune, flatten, prune
end
W->>L: Geometry outputs and assembly authoring outcomes
L->>L: Share eligible static whole definitions within current category publication
L->>L: Share remaining whole meshes; write USD reuse metadata and compact index
L->>T: Output USD stage with rewritten references and dependencies
T->>T: Check authored composition, ownership, animation and interfaces
T->>T: Profile final output USD stage and report results by asset definition
T-->>A: Measured changes, coverage and unresolved work
T-->>D: Final verdict and report/library pathsUse the provided tools for traversal, native operations, authoring and checks; the agent supplies engineering judgments. Preserve current variant selections, authored animation, required materials and interfaces. Trust supported USD Optimize operations with valid settings and scopes. Deep geometric comparisons and whole-scene edit trials belong in development tests, not ordinary execution.
Complete when every unique definition has an executed or evidenced unchanged outcome, every asset has justified ownership and structure, and the written consumer passes composition checks. Retain native failures, unresolved judgments and missing required capabilities as incomplete work. Repeat only affected work when evidence changes.
Scope and authorization
Diagnosis and validation requests remain read-only. An optimization request authorizes work in a separate output workspace within its stated preservation limits.
Never overwrite source layers or inherited libraries without explicit authorization.
Reuse authorization already given. Ask only for a missing decision that changes identity, required appearance or a loss budget; explain the affected component and consequence.
Report only observed changes. Measure rendering before claiming higher FPS or lower GPU use.
Load only the relevant guidance
| Request | Read |
|---|---|
| Validation only | Setup, then the validation section of operations |
| Approved operation chain | Setup, operations, verification |
| Existing or persistent asset library | Add the library index requirements to the assessment |
| Missing standalone runtime | Installation |
| Remote stage | Remote access before the first open |
| Report from completed evidence | Verification |
Use upstream package guidance for selected operation mechanics and proxy workflows. Keep large logs on disk as specified in setup.
Limitations
Convert CAD input with the source converter's workflow and NVIDIA's CAD conversion guidance. Render profiling requires NVIDIA/omniperf or the user's available profiler; USD open and traversal timings alone do not establish rendering improvements.
Troubleshooting
For unavailable imports, operations or remote assets, follow setup. For incomplete execution or failed composition checks, follow verification; retain the failed artifacts and report the missing capability or failed check.
Examples
After runtime preflight, use the verified Python interpreter from setup to inspect a stage:
python scripts/successor_assessment.py inspect --source /data/factory.usdc --workspace /data/factory-reviewReview the generated candidates using boundary guidance, fill the generated decision template, then submit it:
python scripts/successor_assessment.py decide --workspace /data/factory-review --decisions /data/factory-review/decisions.jsonThese commands perform assessment; continue through the instructions above only when review is complete. Run from the skill directory; generated data stays in the workspace.
Output Format
Maintain live progress and editable steering throughout execution.
For end-to-end optimization, provide the written USD assembly, validated report JSON, and generated Markdown and HTML reports. State the runtime, operations actually executed, preservation and coverage results, measured changes, source-write status, and artifact paths. Diagnosis-only work may return a findings summary stating that no optimized stage was written.
Files
- ATTRIBUTION.mdAdded by AutoGineer964 B
- BENCHMARK.md12.0 KiB
- CHANGELOG.md2.4 KiB
- LICENSELicence file added by AutoGineer11.2 KiB
- SKILL.md10.2 KiB
- agents/openai.yaml375 B
- assets/progress-dashboard/app.jsScript9.8 KiB
- assets/progress-dashboard/index.html2.4 KiB
- assets/progress-dashboard/styles.css3.8 KiB
- config/skillspector-baseline.yaml7.3 KiB
- evals/README.md1.8 KiB
- evals/evals.json12.4 KiB
- evals/files/completed-run/after.usda399 B
- evals/files/completed-run/before.usda399 B
- evals/files/completed-run/evidence.json745 B
- evals/files/factory/cases/factory.usda13.6 KiB
- evals/files/factory/materials.usda1.8 KiB
- references/asset-authoring.md10.1 KiB
- references/component_scope.pyScript18.0 KiB
- references/geometry_tolerance.pyScript2.1 KiB
- references/install-standalone.md2.4 KiB
- references/library-reuse.md7.6 KiB
- references/operations.md22.4 KiB
- references/operations/README.md7.9 KiB
- references/operations/operations.json52.4 KiB
- references/operations/registry-args.json2.1 KiB
- references/operations/scripts/operations.schema.json6.2 KiB
- references/optimization-report/scripts/apply_palette.pyScript13.3 KiB
- references/optimization-report/scripts/asset_results.pyScript5.9 KiB
- references/optimization-report/scripts/definition_verification.pyScript7.1 KiB
- references/optimization-report/scripts/descent_convergence_common.pyScript9.0 KiB
- references/optimization-report/scripts/optimization-report.schema.json39.4 KiB
- references/optimization-report/scripts/structure_conformance.pyScript15.2 KiB
- references/optimization-report/scripts/validate_report.pyScript55.2 KiB
- references/remote-assets.md1.6 KiB
- references/report-templates/optimization-report.html.template14.9 KiB
- references/report-templates/optimization-report.md.template6.2 KiB
- references/report-templates/render_preview.pyScript17.9 KiB
- references/report-templates/theme.css711 B
- references/setup-usd-performance-tuning/scripts/probe-snapshot.schema.json1.7 KiB
- references/setup-usd-performance-tuning/scripts/setup-preflight.schema.json6.4 KiB
- references/setup.md3.3 KiB
- references/structure.md20.8 KiB
- references/upstreams/usd-optimize.md6.3 KiB
- references/usd-optimize-run-operations/scripts/asset_authoring.pyScript54.9 KiB
- references/usd-optimize-run-operations/scripts/batch-plan.schema.json7.5 KiB
- references/usd-optimize-run-operations/scripts/category_publication.pyScript6.3 KiB
- references/usd-optimize-run-operations/scripts/current_run_reuse.pyScript11.6 KiB
- references/usd-optimize-run-operations/scripts/material_optimization.pyScript4.9 KiB
- references/usd-optimize-run-operations/scripts/material_publication.pyScript9.5 KiB
- references/usd-optimize-run-operations/scripts/native_reconstruction.pyScript7.9 KiB
- references/usd-optimize-run-operations/scripts/native_worker.pyScript68.4 KiB
- references/usd-optimize-run-operations/scripts/pack_definitions.pyScript1.6 KiB
- references/usd-optimize-run-operations/scripts/persistent_library.pyScript20.3 KiB
- references/usd-optimize-run-operations/scripts/persistent_reuse.pyScript31.1 KiB
- references/usd-optimize-run-operations/scripts/prim_regroup.pyScript14.9 KiB
- references/usd-optimize-run-operations/scripts/run_batch.pyScript32.5 KiB
- references/usd-optimize-run-operations/scripts/semantic_library.pyScript48.2 KiB
- references/usd-optimize-run-operations/scripts/shared_geometry.pyScript25.5 KiB
- references/usd-optimize-run-operations/scripts/status.schema.json7.9 KiB
- references/usd-structure-assessment/references/apply-restructure/scripts/apply-restructure-manifest.schema.json35.3 KiB
- references/usd-structure-assessment/references/usd-hierarchy-dedupe-candidates/scripts/instance_candidate_finder.pyScript12.7 KiB
- references/usd-structure-assessment/references/usd-mesh-fragmentation-candidates/scripts/mesh_fragmentation_finder.pyScript13.8 KiB
- references/usd-structure-assessment/scripts/atomic_placement.pyScript4.9 KiB
- references/usd-structure-assessment/scripts/audit-report.schema.json2.3 KiB
- references/usd-structure-assessment/scripts/boundary_reasoning.pyScript36.0 KiB
- references/usd-structure-assessment/scripts/discovery_preview.pyScript8.6 KiB
- references/usd-structure-assessment/scripts/optimization-plan.schema.json1.5 KiB
- references/usd-structure-assessment/scripts/structure_assessment.pyScript112.2 KiB
- references/usd-structure-assessment/scripts/usd-structure-assessment-report.schema.json14.0 KiB
- references/usd-validation-runner/references/validator-concepts.json35.8 KiB
- references/usd-validation-runner/scripts/usd_validation_executor.pyScript37.4 KiB
- references/usd-validation-runner/scripts/validation-report.schema.json3.5 KiB
- references/usd-validation-runner/scripts/validation-scope-note.schema.json2.6 KiB
- references/usd-validation-runner/scripts/validator-concepts.schema.json3.8 KiB
- references/verification.md11.9 KiB
- scripts/animation_context.pyScript6.8 KiB
- scripts/composition_verification.pyScript16.9 KiB
- scripts/failure_reporting.pyScript2.7 KiB
- scripts/product_clues.pyScript6.2 KiB
- scripts/progress_dashboard.pyScript12.6 KiB
- scripts/stage_profile.pyScript15.7 KiB
- scripts/successor_assessment.pyScript34.1 KiB
- scripts/successor_execution.pyScript15.7 KiB
- scripts/successor_progress.pyScript22.3 KiB
- scripts/successor_reconstruction.pyScript19.6 KiB
- scripts/successor_workflow.pyScript55.0 KiB
- scripts/usd_tuning.pyScript24.7 KiB
- skill-card.md5.5 KiB
- skill.oms.sig26.5 KiB
references/usd-optimize-run-operations/scripts/prim_regroup.py
#!/usr/bin/env python3
# SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
# SPDX-License-Identifier: Apache-2.0
"""Move caller-selected USD prims beneath owners while retaining placement.
Only the selected local layer stack is copied. Reference and payload dependencies
remain external; native namespace editing updates paths and authors relocates.
"""
from __future__ import annotations
import json
from pathlib import Path
def remap_path(path, root_path_map):
"""Apply a moved-root prefix to a prim or property path, returning Sdf.Path."""
from pxr import Sdf
path = Sdf.Path(path)
for prefix in path.GetPrefixes():
destination = root_path_map.get(str(prefix))
if destination is not None:
return path.ReplacePrefix(prefix, Sdf.Path(destination))
return path
def _chain(prim):
"""Contributing transform ancestors in root-to-leaf order."""
from pxr import UsdGeom
chain = []
while prim and not prim.IsPseudoRoot():
xform = UsdGeom.Xformable(prim)
if xform:
chain.append(prim)
if xform.GetResetXformStack():
break
prim = prim.GetParent()
return list(reversed(chain))
def _ancestors(prim):
while prim and not prim.IsPseudoRoot():
yield prim
prim = prim.GetParent()
def _copy_attribute(attribute, target):
# Native property flattening resolves only this inherited property, including
# layer offsets and authored samples; it does not flatten composed geometry.
attribute.FlattenTo(target)
# USD 25.11 may return a stale property handle on a referenced prim.
if not target.GetAttribute(attribute.GetName()):
raise RuntimeError(f'Copy inherited attribute {attribute.GetPath()} to {target.GetPath()} failed')
def _copy_transform(stage, source, path, inverse=False):
from pxr import UsdGeom
target = UsdGeom.Xform.Define(stage, path)
order = [str(token) for token in UsdGeom.Xformable(source).GetXformOpOrderAttr().Get() or []
if str(token) != '!resetXformStack!']
for attribute in source.GetAttributes():
if attribute.GetName().startswith('xformOp:'):
_copy_attribute(attribute, target.GetPrim())
if inverse:
order = [token[len('!invert!'):] if token.startswith('!invert!') else '!invert!' + token
for token in reversed(order)]
target.GetXformOpOrderAttr().Set(order)
def _check_destination(original, destination):
"""Reject inheritance that USD cannot cancel beneath the chosen owner."""
from pxr import Usd, UsdGeom, UsdShade
original_names = {str(var.GetPrimvarName()) for var in
UsdGeom.PrimvarsAPI(original).FindPrimvarsWithInheritance() if var.HasAuthoredValue()}
destination_names = {str(var.GetPrimvarName()) for var in
UsdGeom.PrimvarsAPI(destination).FindPrimvarsWithInheritance() if var.HasAuthoredValue()}
if destination_names - original_names:
raise ValueError(f'Destination {destination.GetPath()} adds inherited primvars absent from {original.GetPath()}')
for purpose in ('', 'preview', 'full'):
original_material, _ = UsdShade.MaterialBindingAPI(original).ComputeBoundMaterial(purpose)
destination_material, _ = UsdShade.MaterialBindingAPI(destination).ComputeBoundMaterial(purpose)
if destination_material and not original_material:
raise ValueError(f'Destination adds an inherited material absent from {original.GetPath()}')
source_ancestors = {prim.GetPath() for prim in _ancestors(original.GetParent())}
for ancestor in _ancestors(destination):
if ancestor.GetPath() in source_ancestors:
continue
visibility = ancestor.GetAttribute('visibility')
if visibility and visibility.HasAuthoredValueOpinion():
if any(visibility.Get(time) == 'invisible' for time in [Usd.TimeCode.Default()] + visibility.GetTimeSamples()):
raise ValueError(f'Destination visibility cannot be cancelled beneath {ancestor.GetPath()}')
for relation in ancestor.GetRelationships():
if relation.GetName().startswith('material:binding:collection:') and relation.HasAuthoredTargets():
raise ValueError(f'Destination collection binding cannot be cancelled beneath {ancestor.GetPath()}')
if (relation.GetName().startswith('material:binding') and relation.HasAuthoredTargets()
and UsdShade.MaterialBindingAPI.GetMaterialBindingStrength(relation) == 'strongerThanDescendants'):
raise ValueError(f'Destination material binding cannot be cancelled beneath {ancestor.GetPath()}')
def _placement(stage, original, owner):
from pxr import Gf, UsdGeom
holder_path = owner.GetPath().AppendChild('__placement_' + original.GetName())
holder = UsdGeom.Xform.Define(stage, holder_path)
holder.GetPrim().SetCustomDataByKey('usdTuning:placement', True)
parent_path = holder_path
# Each visibility opinion keeps its own ancestor so USD combines animated
# invisibility exactly as before the move.
for index, ancestor in enumerate(_ancestors(original.GetParent())):
attribute = ancestor.GetAttribute('visibility')
if attribute and attribute.HasAuthoredValueOpinion():
parent_path = parent_path.AppendChild('visibility' + str(index))
target = UsdGeom.Xform.Define(stage, parent_path).GetPrim()
_copy_attribute(attribute, target)
xform = UsdGeom.Xformable(original)
source_chain = [] if xform and xform.GetResetXformStack() else _chain(original.GetParent())
owner_chain = _chain(owner)
animated = any(attr.GetNumTimeSamples() for ancestor in source_chain + owner_chain
for attr in ancestor.GetAttributes() if attr.GetName().startswith('xformOp:'))
if animated:
for label, chain, inverse in [('destination', list(reversed(owner_chain)), True),
('source', source_chain, False)]:
for index, ancestor in enumerate(chain):
parent_path = parent_path.AppendChild(label + str(index))
_copy_transform(stage, ancestor, parent_path, inverse)
else:
cache = UsdGeom.XformCache()
source_world = cache.GetLocalToWorldTransform(original.GetParent()) if source_chain else Gf.Matrix4d(1)
owner_world = cache.GetLocalToWorldTransform(owner)
if owner_world.GetDeterminant() == 0:
raise ValueError(f'Destination transform is singular: {owner.GetPath()}')
UsdGeom.Xformable(stage.GetPrimAtPath(parent_path)).AddTransformOp().Set(source_world * owner_world.GetInverse())
return parent_path.AppendChild(original.GetName())
def _inherit_state(original, moved):
from pxr import UsdGeom, UsdShade
for var in UsdGeom.PrimvarsAPI(original).FindPrimvarsWithInheritance():
for attribute in (var.GetAttr(), var.GetIndicesAttr()):
if attribute and attribute.HasAuthoredValueOpinion():
_copy_attribute(attribute, moved)
imageable = UsdGeom.Imageable(original)
if imageable:
UsdGeom.Imageable(moved).CreatePurposeAttr(imageable.ComputePurpose())
_inherit_materials(original, moved.GetStage())
if UsdGeom.Xformable(moved):
UsdGeom.Xformable(moved).SetResetXformStack(False)
def _inherit_materials(original, stage):
from pxr import Usd, UsdShade
# Only bindings inherited across the removed ancestry need materializing.
# Collection bindings can select descendants without binding the root.
has_collections = any(relation.GetName().startswith('material:binding:collection:')
and relation.HasAuthoredTargets()
for ancestor in _ancestors(original.GetParent())
for relation in ancestor.GetRelationships())
prims = Usd.PrimRange(original, Usd.TraverseInstanceProxies()) if has_collections else (original,)
for prim in prims:
for purpose in ('', 'preview', 'full'):
material, relation = UsdShade.MaterialBindingAPI(prim).ComputeBoundMaterial(purpose)
if not material or relation.GetPrim().GetPath().HasPrefix(original.GetPath()):
continue
target = stage.GetPrimAtPath(prim.GetPath())
if target.IsInstanceProxy():
root_material, _ = UsdShade.MaterialBindingAPI(original).ComputeBoundMaterial(purpose)
if not root_material or root_material.GetPath() != material.GetPath():
raise ValueError(f'Inherited collection binding on instance proxy cannot be authored: {prim.GetPath()}')
continue
UsdShade.MaterialBindingAPI.Apply(target).Bind(
UsdShade.Material(stage.GetPrimAtPath(material.GetPath())),
UsdShade.MaterialBindingAPI.GetMaterialBindingStrength(relation), purpose)
def regroup(source_layer, output_layer, memberships, *, create_owners=()):
"""Move disjoint source roots to existing owners or explicitly created Xforms.
Instance proxies and destination-only inherited primvars, invisibility or
stronger material bindings are unsupported. Native namespace edit failures
identify the moved root and never produce a successful result.
"""
from pxr import Sdf, Tf, Usd, UsdGeom, UsdUtils
source_layer, output_layer = Path(source_layer).resolve(), Path(output_layer).resolve()
if not isinstance(memberships, dict) or not memberships:
raise ValueError('A nonempty memberships object is required')
if not source_layer.is_file():
raise ValueError(f'Source layer does not exist: {source_layer}')
if output_layer.exists() or source_layer == output_layer:
raise ValueError('A new output path distinct from the source is required')
if not isinstance(create_owners, (list, tuple)) or any(not isinstance(p, str) for p in create_owners):
raise ValueError('create_owners must be an array of destination paths')
for path, owner in memberships.items():
if not all(isinstance(p, str) and Sdf.Path(p).IsAbsolutePath() and Sdf.Path(p).IsPrimPath()
for p in (path, owner)):
raise ValueError('Membership paths must be absolute prim paths')
created = set(create_owners)
if len(created) != len(create_owners) or not created.issubset(memberships.values()):
raise ValueError('Created owners must be unique membership destinations')
source = Usd.Stage.Open(str(source_layer))
if not source or source.GetCompositionErrors():
raise ValueError('Invalid source composition')
holders = set()
source_paths = {Sdf.Path(path) for path in memberships}
for owner in set(memberships.values()):
prim = source.GetPrimAtPath(owner)
if owner in created:
if prim:
raise ValueError(f'Created owner already exists: {owner}')
prim = source.GetPrimAtPath(Sdf.Path(owner).GetParentPath())
if (not prim or prim.IsPseudoRoot() or not prim.IsActive() or prim.IsInstance()
or prim.IsInstanceProxy() or prim.IsInPrototype()):
raise ValueError(f'Owner requires an existing editable parent or prim: {owner}')
for path, owner in memberships.items():
original = source.GetPrimAtPath(path)
if not original or not original.IsActive() or original.IsInstanceProxy() or original.IsInPrototype():
raise ValueError(f'Source must be an active editable prim, not an instance proxy: {path}')
if (any(prefix in source_paths for prefix in Sdf.Path(owner).GetPrefixes())
or any(prefix in source_paths for prefix in Sdf.Path(path).GetParentPath().GetPrefixes())):
raise ValueError('Source subtrees must be disjoint and owners must not move')
holder = Sdf.Path(owner).AppendChild('__placement_' + original.GetName())
if holder in holders or source.GetPrimAtPath(holder):
raise ValueError(f'Placement path already exists: {holder}')
holders.add(holder)
destination = source.GetPrimAtPath(Sdf.Path(owner).GetParentPath() if owner in created else owner)
_check_destination(original, destination)
# FlattenLayerStack merges only local layer opinions and anchors asset paths.
# References, payloads, variants and instances remain composition arcs. Only
# this anonymous layer is editable; no dependent stages are registered.
working_layer = UsdUtils.FlattenLayerStack(source)
stage = Usd.Stage.Open(working_layer)
stage.SetInterpolationType(source.GetInterpolationType())
for owner in sorted(created):
UsdGeom.Xform.Define(stage, owner)
mappings = {}
for path, owner_path in memberships.items():
original = source.GetPrimAtPath(path)
destination = _placement(stage, original, stage.GetPrimAtPath(owner_path))
# Author inherited opinions at the old path before the namespace edit so
# native remapping also sees their relationship and connection targets.
_inherit_state(original, stage.OverridePrim(path))
mappings[path] = str(destination)
for path, destination in mappings.items():
editor = Usd.NamespaceEditor(stage)
try:
if not editor.MovePrimAtPath(path, destination):
raise RuntimeError(f'NamespaceEditor.MovePrimAtPath failed for {path}')
can_apply = editor.CanApplyEdits()
if not can_apply:
raise ValueError(f'NamespaceEditor cannot move {path}: {can_apply.whyNot}')
if not editor.ApplyEdits():
raise RuntimeError(f'NamespaceEditor.ApplyEdits failed for {path}')
except Tf.ErrorException as error:
error.add_note(f'NamespaceEditor move {path} to {destination}')
raise
output_layer.parent.mkdir(parents=True, exist_ok=True)
if not working_layer.Export(str(output_layer)):
raise RuntimeError(f'Export regrouped layer failed: {output_layer}')
return {'status': 'regrouped', 'source_layer': str(source_layer),
'output_layer': str(output_layer), 'root_path_map': mappings,
'created_owner_paths': sorted(created)}
def main():
import argparse
parser = argparse.ArgumentParser(description=__doc__)
parser.add_argument('source_layer')
parser.add_argument('output_layer')
parser.add_argument('--memberships', required=True, help='JSON file mapping source prim paths to owners')
parser.add_argument('--create-owners', help='JSON file containing an array of new Xform owner paths')
parser.add_argument('--report', required=True)
args = parser.parse_args()
result = regroup(args.source_layer, args.output_layer,
json.loads(Path(args.memberships).read_text()),
create_owners=json.loads(Path(args.create_owners).read_text()) if args.create_owners else ())
Path(args.report).write_text(json.dumps(result, indent=2) + '\n')
return 0
if __name__ == '__main__':
raise SystemExit(main())
Requirements and compatibility
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Needs: Needs Python, Needs Node.js
The author says: Requires a verified standalone Usd Optimize/OpenUSD runtime for operations, usd-validation-nvidia for supported checks, and a writable output workspace. Remote assets require a working resolver. Render profiling is an external handoff.
Security
What our scanner noticed· Medium risk
- Large base64-encoded blobs
- Scripts that your agent may run
This skill includes scripts that your agent may run. Read them before you use it.
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Created by
- NVIDIA Omniverse
- Publisher
- NVIDIA (Official)
- Source
- NVIDIA/skills · skills/omniverse-usd-performance-tuning · commit fce3cca
- Licence
- Apache License 2.0 (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE-APACHE)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
AutoGineer is not affiliated with or endorsed by NVIDIA Omniverse or NVIDIA.
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download omniverse-usd-performance-tuning.zip