You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fixes infinite loop in repeated_objects_terrain: respawn only wrong object samples (#1612)
# Description
Currently, the
[`repeated_objects_terrain`](https://github.com/isaac-sim/IsaacLab/blob/v1.4.0/source/extensions/omni.isaac.lab/omni/isaac/lab/terrains/trimesh/mesh_terrains.py#L721)
function attempts to respawn all *N* required objects if even a single
object lies within the central platform. However, the probability of
successfully spawning *all objects* outside the central platform depends
on the object density (i.e., the number of required objects relative to
the terrain size) and the size of the central platform. For high object
densities, this probability quickly approaches zero, causing the
function to enter an infinite respawn loop.
This PR addresses the issue by respawning only the objects that lie
within the central platform during each loop, while leaving objects
outside the platform untouched. This leads to faster terrain generation
and prevents the worst-case scenario of getting stuck in an infinite
respawn loop when object density is high.
## Type of change
<!-- As you go through the list, delete the ones that are not
applicable. -->
- Bug fix (non-breaking change which fixes an issue)
## Checklist
- [x] I have run the [`pre-commit` checks](https://pre-commit.com/) with
`./isaaclab.sh --format`
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [ ] 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
-->
---------
Signed-off-by: Nicola Loi <[email protected]>
Copy file name to clipboardExpand all lines: source/extensions/omni.isaac.lab/docs/CHANGELOG.rst
+9Lines changed: 9 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,15 @@
1
1
Changelog
2
2
---------
3
3
4
+
0.30.5 (2025-01-14)
5
+
~~~~~~~~~~~~~~~~~~~
6
+
7
+
Fixed
8
+
^^^^^
9
+
10
+
* Fixed the respawn of only wrong object samples in :func:`repeated_objects_terrain` of :mod:`omni.isaac.lab.terrains.trimesh` module. Previously, the function was respawning all objects in the scene instead of only the wrong object samples, which in worst case could lead to infinite respawn loop.
0 commit comments