Jump to content
ikatz001

Cloth Sim Speed

Recommended Posts

Hi,

 
I have Houdini Indie,
 
I am trying to simulate a cloth animation and am getting very, very slow results. 
 
I am doing a simple grid with 100 by 100 res fall into a smaller cube. On the default Finite Element Solver settings it is taking close to a minute per frame. If I increase the res of my mesh to 300 by 300 it gets close to 12 min per frame (I am running dual high end xeons, 256GB RAM, Quadro4200 and Tesla K40c). I am not even seeing good CPU utilization hovering between 9 and 12%
 
I tried to disable substepping and setting the Max Iterations Linear Solve to 128 but it barely has any effect.
 
Is this normal behavior or can I assume something is wrong??
 
Thanks,
 

Share this post


Link to post
Share on other sites
Guest tar

This is a very effective method for Cloth in H14:

 

1. Use a lower res mesh to simulate with

2. Run a DivideSop and maybe a PolyDoctorSop to make a nice tri-mesh to simulate with

3. turn off the Collide options on the Cloth Object

3.5 work on your dynamic forces.

4. once you have all your dynamics looking good then turn on the Collide option you need, 'Collide with self' should be the last thing to turn on and bake out the results

5. Use the Cloth Proxy to attach the of the lower res simulation to a higher res hero mesh.

 

Make sure to use the Cloth recipes in the documentaion to avoid the rubber look!

 

Using the above method you should be able to get ~12+ fps when working on the dynamics.

Share this post


Link to post
Share on other sites

Thanks for the answer Marty. I will definitely give this a try. Even though most of my sim is about self collisions and not dynamic forces so I dont know how useful it will be for me. And as I mentioned in the Hforums, I am getting significantly different results in behavior when I change the rez of the mesh (apart from details), what Im looking for is the actual behavior of a high rez mesh. I do wish SES people would work on improving the speed instead of having to resort to these sorts of methods.

 

Thanks in any case ;)

Share this post


Link to post
Share on other sites
Guest tar

If you are seeing major differences between the low res and high res simulations, please upload an example here and we can take a look.

 

In regards to the mini-rant at Sesi on the Sesi forums; we don't do that much here, we look for solutions. Obviously everyone wants extremely high-performance but we work with the tools we have and find the best possible methods.  You may want to look up the engineering uses of FEM and see that it is the method for simulations. In regards to it's advantages - it can interact with a lot of the solvers and therefore is extremely integrated into the dynamics of the package.

 

You may have missed it but H15 Sneak Preview did mention 'faster FEM' in the final slide.

Share this post


Link to post
Share on other sites

I must admit I just chose ncloth for the cloth in my current project, because of the speed and the really nice out of the box air drag behavior. That being said, while looking into using houdini, the "remesh" sop was great to build the simulation mesh  (which you can then use with cloth capture and cloth deform).

Cheers,

koen

Share this post


Link to post
Share on other sites
Guest tar

Here's a nice floppy looking Houdini cloth. It solved at ~40fps.

 

Using the recipes from the documents as a starting point, for a silky-like material and turning off self-collision makes for a super cool iterated design workflow.

 

The main advantage is then keeping a procedural solution within Houdini.   In my experience, most people simply aren't playing with cloth as it appears to be out of the box rubber-like and slow. Remove that two factors and there isn't too much advantages in other packages. 

 

InClothd2.hipnc - with deforming collision geo solves at ~12-20fps

 

ClothFlag - is a floppy flag, with added some extra weight to the top right corner, and it solves at ~27fps.

 

When I look a real flag, it's hardly a mathematically perfect bit go cloth, it's damaged from blowing in the wind, it's wrinkled, it has stitching and print on it, that adds weight and drag, it is attached to a bending frame or rope. so, the best way to make it real in the computer is to start add 'imperfections'; one simple touch of weight at the top right adds a more real look. Other packages may do this automagically, but I'm assuming most people aren't doing it in Houdini as the initial experience is similar to the OP.

 

Edit: Click on pics to see .gifs

post-8321-0-55384700-1441482181_thumb.gi

Clothd.hipnc

Clothd2.hipnc

ClothdFlag.hipnc

post-8321-0-67965400-1441483620_thumb.gi

Edited by tar

Share this post


Link to post
Share on other sites
Guest tar

 That being said, while looking into using houdini, the "remesh" sop was great to build the simulation mesh  (which you can then use with cloth capture and cloth deform).

 

 

Interestingly Marvellous Designer's mesh looks like the remeshSop too. MD5 is available as an open beta for anyone who is interested 

 

 

 
I am doing a simple grid with 100 by 100 res fall into a smaller cube. On the default Finite Element Solver settings it is taking close to a minute per frame. If I increase the res of my mesh to 300 by 300 it gets close to 12 min per frame (I am running dual high end xeons, 256GB RAM, Quadro4200 and Tesla K40c). I am not even seeing good CPU utilization hovering between 9 and 12%
 

 

 

Not seeing this here on dual Xeons 5680 @ 3.33. ~5-10sec/frame for 100x100 and ~20~95sec/frame for 300x300

Share this post


Link to post
Share on other sites

In addition to what marty mentioned about FEM in H15 (my goodness FEM is so much faster in 15!!) the other cloth workflow in H14 is the grain solver with creation method set to "sheet".

 

You can get extremely fast and easy to control results with this solver, i'd recommend looking into as a possible solution. 

 

Cheers.

Share this post


Link to post
Share on other sites

In addition to what marty mentioned about FEM in H15 (my goodness FEM is so much faster in 15!!) the other cloth workflow in H14 is the grain solver with creation method set to "sheet".

 

You can get extremely fast and easy to control results with this solver, i'd recommend looking into as a possible solution. 

 

Cheers.

  Shit I didn't see that in the changeolog ! Gonna have to try that out when I get home :D

Share this post


Link to post
Share on other sites

Hi Guys! I found one interesting bug. Drag force doesn't work at H15. In H14 everything okay with it. Please can somebody test it? Maybe I did something wrong.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×