Found 48 posts.
Search results Show results as topic list.
Work in Progress » VS Code in Houdini
- orr
- 98 posts
- Offline
Houdini Lounge » Thoughts on NeuralVDB/AI Simulation Tech
- orr
- 98 posts
- Offline
wyhinton1
Honestly I might give applying a basic PINN a go.
ChatGPT gave me this nice example of the general steps on how to go about using a PINN to speed up a physics solve, btw!
I think the tough part of using the PINN, from my very basic understanding, is that unless you spend the time to build a very large data set, the PINN you train will have a fairly narrow set of applicable use cases.
But lets say you need to refine and iterate a simulation many times, or create many instances of a certain kind of simulation, then the PINN could greatly accelerate that.Step 1: Define the geometry of the system that you want to simulate.
In Houdini, you can create a 3D model of the system that you want to simulate using its built-in modeling tools. For example, you could create a simple geometry, such as a ball falling onto a plane.
Step 2: Use a physics engine to simulate the system and generate observational data.
In Houdini, you can use its built-in physics engine to simulate the system and generate observational data. For example, you could set up a rigid body simulation where the ball falls onto the plane and bounces off.
Step 3: Train a PINN using the observational data and the physical laws that govern the system's behavior.
To train the PINN, you need to provide it with both the observational data and the physical laws that govern the system's behavior. For example, in the case of the ball falling onto a plane, you could provide the PINN with the initial position and velocity of the ball, as well as the laws of gravity and collision.
In Houdini, you could use a machine learning framework, such as TensorFlow or PyTorch, to create and train the PINN. You would need to define the PINN architecture and loss function, and then train the network using the observational data and physical laws as inputs.
Step 4: Use the trained PINN to predict the system's behavior under different conditions, instead of simulating it using the physics engine.
Once you have trained the PINN, you can use it to predict the system's behavior under different conditions. For example, you could use the PINN to predict how the ball would behave if it was dropped from a different height or if it was made of a different material.
In Houdini, you could create a new simulation where you input the different conditions and use the trained PINN to generate the simulation results.
To summarize, in this basic example, you could use Houdini to create a simple 3D model, simulate it using its built-in physics engine, train a PINN using the observational data and physical laws, and use the trained PINN to predict the system's behavior under different conditions. This approach can significantly reduce the computational cost of the simulation, as the PINN can make predictions much faster than the physics engine can simulate the system.
Besides PINNs, differentiable simulations are a very interesting field right now. You can check out nvidias wrap for example here [developer.nvidia.com]. One of the ideas is that you can compute the gradient of your input parameters through the simulation. This would in theory allow you to optimize for the initial parameters of your simulation from a given final state.
For example, and was shown in a talk by Miles Macklin, you want a piece of cloth to land on a ball, and by using the automatically computed gradient you can optimize for the initial velocity and force that will cause the cloth to land on the ball. This is a very simplistic example, but I think it gives an idea of where this could go, and it is already used in the deep RL community.
There is a houdini wrap plugin, but it does not allow you to perform gradient computations yet as far as I know.
Houdini Lounge » Thoughts on NeuralVDB/AI Simulation Tech
- orr
- 98 posts
- Offline
I agree, it would be nice for Houdini not to lose its eye on innovation. Other than implementing most recent methods in neural graphics I would love to see Houdini enable users to make tools of their own. A Tensor Operator Context (TEOps) with automatic differentiation or a differentiable operators context (DIFOps) where every operator can compute gradients for backpropagation (like NVIDIAs Warp) would be great. If you look at Neural Fields, Differentiable Simulations, PINNs there is a lot out there that Houdinis toolset is not adapted to yet but will soon become relevant for vfx.
PDG/TOPs » changing parms from a external process
- orr
- 98 posts
- Offline
tpetrick
I think the problem in your case is that need to save the .hip after setting the parms. The parm you're setting is on the ROP node targeted for the cook, not on the TOP node itself. The parms on that ROP are not evaluated by PDG, but by ROPs itself when the job is cooking out of process. E.g.:
- PDG generates a ROP work item to cook the node “/obj/topnet1/ropgeometry1”, and sets the target hip to $HIP
- The job is scheduled locally/on the farm
- The job starts hython, loads the specified .hip file, and cooks the ROP
So if the .hip is not saved, the parm change won't be available.
The reason it works when you change the parms in the current Houdini session is that Houdini will normally pop up a graphical dialog prompting you to save you .hip before cooking the TOP network. There's a button on that dialog to “Do this every time”, which makes the saving happen automatically, but that option is stored as part of the dialog system. In a non graphical session, it doesn't enter the code path to check if the .hip file needs to saved.
I think we can fix it so that it always saves the .hip before cooking the TOP network in a non-graphical session, but in the mean time you can do that through hou.HipFile.
I see. That makes sense. Thanks so much for clarifying.
PDG/TOPs » changing parms from a external process
- orr
- 98 posts
- Offline
coleclough
Hello there. I seem to be having a similar issue, possibly with the same underlying cause.
I have made a topnet inside of my HDA that cooks textures. Parameters from the topnet are promoted to the HDA interface however cooking from the HDA interface (using hou.TopNode.executeGraph(1,0,0,0)) doesn't update the parameters on the top nodes, leading the graph to always cook with the same parameters as your first cook that session, unless you shift+v.
Forgive me if I am missing an obvious function. I have tried cooking using hou.TopNode, pdg.GraphContext and pdg.Node, all of which yield the same results. I have also tried hou.TopNode.dirtyTasks/AllTasks(0/1) and pdg.Node.dirty(0/1)
This is a big issue as it really hinders the usability of my HDA.
Hey. Interesting. For me some parameters do update and some don|t. A workaround for me is to set the attributes in the top network through a csv file and then use those attributes as parameters for the other tops. Maybe that helps.
PDG/TOPs » changing parms from a external process
- orr
- 98 posts
- Offline
chrisgreb
Could you clarify what your setup is:
What ‘external process’ do you mean?
When you say the code runs several times do you mean one process in a loop or sequentially in different processes?
Yes of course. The external process is a python script loading hou through rpc to communicate with an open houdini instance, which usually works well. I see that the parameter is set by the script and it works for any other PDG nodes (for example csvoutput), but it in this case during cooking it's just ignored. The above code is running in the script in a loop where geopath changes every iteration.
If I set the parameter through the script above and cook it manually (shift+V) in houdini, everything works and the files are written to the right location given by the parameter.
PDG/TOPs » changing parms from a external process
- orr
- 98 posts
- Offline
Hi All,
I am trying to execute a pdg graph from a external process. I do something like this…
This code runs several times with different geopath values. It works well.
However, once geopath is changed in the external process, and the graph is executed again, it'll still save to the location that was given the very first time. So, I assume I am not getting something here or the parm values are cached somewhere. Any help would be much appreciated.
Thanks,
I am trying to execute a pdg graph from a external process. I do something like this…
hou.node("/obj/topnet1/ropgeometry1").parm('sopoutput').set(geopath) hou.node("/obj/topnet1/").dirtyAllTasks(False) hou.node("/obj/topnet1/").executeGraph(False, True, True, True) hou.node("/obj/topnet1/ropgeometry1").getPDGGraphContext().cook(True)
This code runs several times with different geopath values. It works well.
However, once geopath is changed in the external process, and the graph is executed again, it'll still save to the location that was given the very first time. So, I assume I am not getting something here or the parm values are cached somewhere. Any help would be much appreciated.
Thanks,
Technical Discussion » hqueue independent frames
- orr
- 98 posts
- Offline
Hi All,
I have a hqueue setup where I would want to run an animation where all frames can cook independently of each other.
Is there a way to specify this through either the hqueue rop directly or the remote API?
Thanks,
I have a hqueue setup where I would want to run an animation where all frames can cook independently of each other.
Is there a way to specify this through either the hqueue rop directly or the remote API?
Thanks,
Technical Discussion » Tensorflow workaround
- orr
- 98 posts
- Offline
Is there a reason you cannot pre-generate your datasets before training and use them in a python 3 environment?
I have tensorflow installed on windows under python 2.7 in a sperate python environment outside of Houdini. The issue in Houdini on Windows is much more about the binary compatibility of the libraries you install.
I have tensorflow installed on windows under python 2.7 in a sperate python environment outside of Houdini. The issue in Houdini on Windows is much more about the binary compatibility of the libraries you install.
Technical Discussion » How to use scipy with Houdini 17 on windows?
- orr
- 98 posts
- Offline
As far as I know the python distribution that comes with Houdini on Windows was compiled with Visual Studio 2017. You can read this of from the first line in the python shell
Python 2.7.15 (default, Jan 13 2019, 12:40:45) on win32
So whatever you want to add to Houdini on Windows needs to be compiled with the same version ( MSC v.1916 ). Unfortunately, I wasn't able to find any scipy binaries compiled with this particular compiler for python 2.7. So I guess if you don't want to compile it yourself, and sesi cannot do that for you, it might challenging to get it to work.
Depending on your usecase there might be certain workarounds possible. But all of them are not ideal.
Please let me know if you find any solution working for you.
Python 2.7.15 (default, Jan 13 2019, 12:40:45) on win32
So whatever you want to add to Houdini on Windows needs to be compiled with the same version ( MSC v.1916 ). Unfortunately, I wasn't able to find any scipy binaries compiled with this particular compiler for python 2.7. So I guess if you don't want to compile it yourself, and sesi cannot do that for you, it might challenging to get it to work.
Depending on your usecase there might be certain workarounds possible. But all of them are not ideal.
Please let me know if you find any solution working for you.
Technical Discussion » How to use scipy lib of python in Houdini ?
- orr
- 98 posts
- Offline
As far as I know the python distribution that comes with Houdini on Windows was compiled with Visual Studio 2017. You can read this of from the first line in the python shell
Python 2.7.15 (default, Jan 13 2019, 12:40:45) on win32
So whatever you want to add to Houdini on Windows needs to be compiled with the same version ( MSC v.1916 ). Unfortunately, I wasn't able to find any scipy binaries compiled with this particular compiler for python 2.7. So I guess if you don't want to compile it yourself, and sesi cannot do that for you, it might challenging to get it to work.
Depending on your usecase there might be certain workarounds possible. But all of them are not ideal.
Please let me know if you find any solution working for you.
Python 2.7.15 (default, Jan 13 2019, 12:40:45) on win32
So whatever you want to add to Houdini on Windows needs to be compiled with the same version ( MSC v.1916 ). Unfortunately, I wasn't able to find any scipy binaries compiled with this particular compiler for python 2.7. So I guess if you don't want to compile it yourself, and sesi cannot do that for you, it might challenging to get it to work.
Depending on your usecase there might be certain workarounds possible. But all of them are not ideal.
Please let me know if you find any solution working for you.
Houdini Lounge » 17.5 Announcement
- orr
- 98 posts
- Offline
Technical Discussion » How to use scipy with Houdini 17 on windows?
- orr
- 98 posts
- Offline
Technical Discussion » vc14?
- orr
- 98 posts
- Offline
Hi,
Since houdini 15.5 has switched to vc14, my understanding is that we can now use visual studio 2015 do develop plug-ins for H. Is this correct?
Thanks,
Since houdini 15.5 has switched to vc14, my understanding is that we can now use visual studio 2015 do develop plug-ins for H. Is this correct?
Thanks,
Technical Discussion » array attributes to python
- orr
- 98 posts
- Offline
I have a per-point integer array attribute which I would like to access in python but when I try to so I get only zeros. Are array attributes accessible with the “point.attribValue(“attribname”)” method?
Houdini Lounge » 1bit bitmaps
- orr
- 98 posts
- Offline
Houdini Lounge » 1bit bitmaps
- orr
- 98 posts
- Offline
Hi Everyone,
Is there a way to save bitmaps with 1bit bit-depth from cops inside of Houdini?
Thanks
Is there a way to save bitmaps with 1bit bit-depth from cops inside of Houdini?
Thanks
Houdini Lounge » Save groups into seperate files
- orr
- 98 posts
- Offline
Houdini Lounge » Save groups into seperate files
- orr
- 98 posts
- Offline
Hi Everyone,
Say I have a SOP with n (where n is large) groups and I want to save every group into a separate obj file with a distinct name. Is there a quick way to do this without using a numbered naming convention?
Thanks
Say I have a SOP with n (where n is large) groups and I want to save every group into a separate obj file with a distinct name. Is there a quick way to do this without using a numbered naming convention?
Thanks
Houdini Lounge » Invisible Houdini Nodes
- orr
- 98 posts
- Offline
-
- Quick Links