Isaac Sim Version
4.2.0
Operating System
Ubuntu 20.04
GPU Information
- Model: RTX 4070 Super Ti
- Driver Version: 550.78
I am not able to understand Replicator behvaiour
Detailed Description
For synthetic data generation i use replicator to randomize few things like lights, colors etc.
In order to control the randomiztaion i use replicator with custom event names like
- rep.utils.send_og_event(event_name=“randomize_lights”)
- rep.utils.send_og_event(event_name=“randomize_dome_background”)
-rep.utils.send_og_event(event_name=“randomize_shape_distractor_colors”)
After calling the replicator with custom events, i use rep.orchestrator.step() to render the scene
- To render the scene
rep.orchestrator.step(rt_subframes=8, delta_time=0.0)
rep.orchestrator.wait_until_complete()
Till now everything works fine but if I use rep.orchestrator.step() two times then the replicator at custom events does not work.
Let me explain in detail.
I want to render a prim for bounding box but do not want the prim to be visible in the image.
(like mentioned here - How to render the absence of a prim/mesh or part of a prim/mesh? )
Hence I make the object / prim visible when capturing bounding box data and make object invisible when capturing rgb image data. For this I need to use rep.orchestrator.step() twice
prim.MakeVisible()
rep.orchestrator.step(rt_subframes=8, delta_time=0.0)
rep.orchestrator.wait_until_complete()
-----capture bbox data using annotators---------
prim.MakeInvisible()
rep.orchestrator.step(rt_subframes=8, delta_time=0.0)
rep.orchestrator.wait_until_complete()
-----capture rgb image data using annotators---------
But when I use rep.orchestrator.step(rt_subframes=8, delta_time=0.0) twice in the loop of generating synthetic data the replicator randomizations at custom event do not takes place. For example the dome light texture does not change even though the replicator is called at custom events.
In general I think using replciator at custom events does not work if I use rep.orchestrator.step() two times.
The other option is to use omni.glass material for the object to be transperant in image data and still have bbox without using MakeVisible() and MakeInvisible(). But then the transperant object is still faintly visible in the rgb image.
I am more interested in turning off and on visibility of prim as it provides greater control. But then I am unable to use replicator randomizations which are automatic and easy to use.
Is there any way to solve this
Steps to Reproduce
- In a loop call replicator at custom events
for i in range(100):
rep.utils.send_og_event(event_name="randomize_lights")
rep.utils.send_og_event(event_name="randomize_dome_background")
rep.utils.send_og_event(event_name="randomize_shape_distractor_colors")
rep.orchestrator.step(rt_subframes=8, delta_time=0.0)
rep.orchestrator.wait_until_complete()
this works and randomizations takes places.
- not working case
for i in range(100):
rep.utils.send_og_event(event_name="randomize_lights")
rep.utils.send_og_event(event_name="randomize_dome_background")
rep.utils.send_og_event(event_name="randomize_shape_distractor_colors")
rep.orchestrator.step(rt_subframes=8, delta_time=0.0)
rep.orchestrator.wait_until_complete()
rep.orchestrator.step(rt_subframes=8, delta_time=0.0)
rep.orchestrator.wait_until_complete()
this does not works and randomizations do not takes places.