Hython 15.5 memory management problems

   1350   1   0
User Avatar
Member
9 posts
Joined: 8月 2014
Offline
Greetings,

I have a scripted hython process which imports a number of meshes, converts them into a VDB, combines them, and exports the result as a single mesh. I recently reworked the structure of the scene to ideally make it more efficient, but the result has been that input values and data which hython could handle before are now maxing out memory and causing other applications to crash.

The strange part is that this only happens when I run it at the command line. If I open the hip file and input the exact same data, Houdini manages to calculate it in about 30 seconds without disrupting other applications.

The only difference I can work out is that when I input the data manually, Houdini ends up calculating it in stages, caching the results of previous stages, so the final render has less to process.

Is there any way to force hython to do the same thing? What seems to be happening is that no calculations are done until I run hou.parm('myRopNet/execute').pressButton(), and then it gets overwhelmed trying to do it all at once.

I'm using Houdini 15.5.570. Are there any other tools available for controlling memory usage from hython? I've found info on how to purge the cache between multiple frames of a large render, but my output is only one frame.
Edited by Pyraxis - 2016年11月2日 14:26:50
User Avatar
Member
9 posts
Joined: 8月 2014
Offline
Figured it out, it was my own fault. Some parameters were getting propagated incorrectly through the network.

In the process I learned a much better way of debugging: running portions of the hython script directly from the hip scene by adding the defs to the python source editor and calling them from the console with hou.session.whatever().
  • Quick Links