-
I am trying to use Mitsuba 3 to render a lot of scenes in one single execution of a python file, which involves many invokes of mi.load_dict(). After some iterations I will get error |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
Hello @Galaxeaaa, Have a look at the Lines 45 to 63 in c9e881b You should be able to use it, or a subset, to load a large number of scenes in sequence. |
Beta Was this translation helpful? Give feedback.
-
Hi @merlinND, Thank you for your reply! I copied the
Do you have any idea on how to solve this? |
Beta Was this translation helpful? Give feedback.
I'm not sure, it's difficult to tell from the stack trace. The
clean_up()
function is very aggressive and will lead to segfaults if anything from the previously loaded scene is still referenced or used in any way.So I would try to make sure that everything is out of scope (including no "hidden" references via an AD graph) before calling it.
You can also try commenting out different parts of the
clean_up()
function to see if it's enough to reclaim memory while being less aggressive.