Lets talk about Mantaflow


(Tedri Mark) #542

Thanks for the build, however, I can’t seem to get a fluid sim going - I’ve made a cube, set it as a mantaflow domain, and added a sphere and set as a mantaflow liquid , with flow and domain type set to liquid, but hitting ‘A’ doesn’t do anything for me, nor does ‘bake data’ (Although I get the progress bar at the top)

In the most recent build (From march) I had no problems, is there a different workflow I should be doing for your build/?


(Gilles Charbonneau) #543

You need to bake the sim now, you can do so individually, starting by baking the data, then the mesh, then the particles, which is very convenient, as you can tweak all the components individually without having to re-bake everything!


(Tedri Mark) #544

Hmmmm… If I bake the data, with show FLIP enabled, I get a layer of particles in my domain, I’m guessing these represent the surface. However, there’s no animation if I hit ‘A’, and they don’t seem to have anything to do with the sphere that i set as the liquid geometry.

If I then bake the fluid mesh, I get a mesh drawn, but that disappears if I scrub the timeline or hit ‘A’ to animate.

I’m just trying to do the classic 'drop a sphere of water in a cube domain, fluid test, really :slight_smile:


(pierite) #545

Hi, did you tried this way:

  1. apply rotation & scale for all your objects and save your file
  2. in the Fluid Cache Tab, uncheck Relative Path and set a directory
  3. check “show FLIP” in the Fluid Simulation tab and hit the bake data button
  4. play animation

(Tedri Mark) #546

It was the relative path that was doing it. There doesn’t seem to be a ‘relative path’ button in my build, so I had to click to set the directory, then copy and paste it into the field in the fluid cache tab.

Thanks!


(Tedri Mark) #547

Is there any guide anywhere about how to sue the particles that are set up? Ie bubbles


(Gilles Charbonneau) #549

Okay, this is very cool stuff, very powerful, but it takes way to long to compute the data, it took more than 8 hours to calculate 250 frames from the quick fluids scene at a resolution of 256 on a I7 2700K with 16 GB of ram, anyone knows if there are any plans for using OpenCL to speedup calculations?


(davidkollmar) #550

@jensverwiebe do your linux builds support multicore processes? I was running a quick simulation on my computer and mantaflow only seemed to be using one core at any one time. :confused:


(jensverwiebe) #551

I used the default configuration which matches “WITH_OPENMP” but indeed i also see very poor coresaturation here. In a fluidsimulation its highly dependent on how the grids are “filled” but almost only 22% is not very much. Perhaps i shoud deactivate openMP thus fallback to TBB, which is almost always more efficient ( must be tricked atm. ).
In the end only Sebbas can answer the question about the state of multithreading fully.
Btw: i also saw there is an attempt on linux to use multithreaded python. Dunno how far testing with this is right now ( typically python threading is a can of worms ).

EDIT: Best test yourself, 'am a bit rare with time this week. This one is an alternate manta build of the same hash but forced to do multithreading with TBB:

– PACKAGE-INFORMATION –
Branch: fluid-mantaflow
Revision: 1be28f9
Submodules: locale d3349b4 addons 4cb31f5 addons_contrib f178e6c tools ca3e38d
OS: GNU/Linux, Architecture: x86_64, GLIBC: 2.19
Builddate: Mo 11. Jun 08:52:35 UTC 2018
Filesize: 110518172 byte
Sha256sum: 7c8e0000d29cf44ef3bc6474c2e08aa12ded093481df8d2e6eb1c33a05beac85
URL: http://www.jensverwiebe.de/Blender/blender_fluid-mantaflow_tbbtest_linux64_latest.tar.xz

CHANGES SINCE 1be28f9: switched from omp to tbb in manta calculation

Jens


(davidkollmar) #552

OK, thanks

I did some testing with the same simple scene on both builds:
TBB: 33s
OpenMP: 35s
(for both tests the 8-core CPU ran at approx. 35% with relatively even core distribution)

When an obstacle is added to the same scene:
TBB: 3m 19s
OpenMP: 3m 22s
(for both tests the 8-core CPU ran at approx. 20-25% with one core always running at far more than the others, OpenMP alternated the single core far faster than TBB)

It seems that the reason it appeared to be running on single-core was due to the fact that my scene had an obstacle in it (which seems to lower multithreading ability)

Thank you very much for your help! I may try to find the source for the mantaflow branch and do a build on my system to see if it has any better multithreading capabilities (I doubt it will but its worth a shot).


(jensverwiebe) #553

Yo David, you are welcome.
Always keep in mind to have the domain as small as possible.
My testscene ( big wave oscillating ) was calculated double as fast with the tbb version.
Imagine the domain is divided into as much gridcells as you have cores ( incl. HT ). Thus cells
in which less to nothing is happening just idle. Thats a bit simplified but explains the suboptimal
core-saturation. The resolution setting may add up here too.
In the eelbem fluids i had a bit more experience how to get the best of multicores. With manta
it seems the game changed and we have to learn something new .

Cheers … Jens


(esimacio) #554

I made a build from the May 15 Commit, for windows. But it is not working. No simulation at all. Using the same scene I made in December Build


(jensverwiebe) #555

Sometimes the actual repo state seems to stick with initialisation issues.
Try reset to frame 0 and start over and/or let the animation run the
full cycle.
Have not yet found why it does not show the bake, but with a bit fiddling,
i always got it to show up for now.

Jens


(esimacio) #556

I also see that there are some changes in this build regarding baking, that could be the problem.
I will try again and come back with the result


(esimacio) #557

I can’t figure this out, doesnt work, only the particles are baked. If someone want to try here is the build


(fin.eskimo) #558

Hi… just ran a quick test off this build for you… no issues for me.


(Gilles Charbonneau) #559

Having a problem here, the liquid vanishes for some reason, here is the file, if anyone cares about having a look!
mantaflow-beach-test-01.blend (624.5 KB)


(pierite) #560

Hi, same problem for me for my beach waves test :confused:


(Gilles Charbonneau) #561

That, and I am also having problems with fluids being generated at the wrong place on most of my tests, tried to apply scale/location/rotation to the meshes, nothing works, I need to rebuild the scene, which is a pita!


(pierite) #562

Did you tried to centered the pivot point for all your objects ?