Foam Tool not working

Hi,
I've been trying to use the foam tool proposed with the VisualSPH.
I installed everything right (blender, visual sutio 2015, add on...) and followed thoroughly the tutoriel. However, it does not work and I can't guess why.

Have anyone tried it ?

Thanks

Here is the error message in the Blender console:

Traceback (most recent call last):
File "C:\Users\Kraeken\AppData\Roaming\Blender Foundation\Blender\2.79\scripts\addons\VisualSPHysics.py", line 435, in execute
if parseXML(context):
File "C:\Users\Kraeken\AppData\Roaming\Blender Foundation\Blender\2.79\scripts\addons\VisualSPHysics.py", line 159, in parseXML
bpy.context.scene.DsphFoamH = float(xdoc.getElementsByTagName("h")[0].getAttribute("value"))
IndexError: list index out of range

location: :-1

location: :-1

Comments

  • Hi, it looks like the script cannot find the "h" value from the xml. Have you chosen the xml file generated by gencase?
  • Hi @Admin, no ! This was it !! Thanks
    It could be nice to make the wiki on this point more clear
    Chnage "XML: here, select the XML file used for the fluid simulation" to "XML: here, select the XML file generated by gencase"

    Otherwise, the tutoriel is nice. thanks a lot.
  • Thanks for the suggestion! :smiley:
    I've modified the tutorial to make this step more clear.
  • @Admin I've been trying to do the same with one of my own simulation, but no particles are created...
    Looking at the console there some nan and very small values so I wonder... I've tried setting all the min parameter to zero but no change.
    Here is the console feedback:
    Opening: E:\Calcul\Ouvrage\2019-05_CalageFF_DSM_0.003\Blender\..\CalageFF_DSM_out\Particles\PartFluid_0040.vtk
    Number of buckets: 21526120
    Total fluid particles: 632570

    [Stage 1] trapped air potential, Energy and colorfield. Time: 0.219081
    [Stage 2] gradient. Time: 0.367002
    [Stage 3] wave crests. Time: 0.0286482

    Statistics
    ===========
    *** Wave crests ***
    Mean: 0.00671791
    Min: 0
    Max: 5.67105
    Min non-zero: 0.0105506
    *** Trapped air ***
    Mean: -nan(ind)
    Min: -nan(ind)
    Max: -nan(ind)
    Min non-zero: 0.00554384
    *** Energy ***
    Mean: 1.23104e-05
    Min: 1.78793e-10
    Max: 9.88331e-05
    Min non-zero: 1.78793e-10

    [Stage 4] clamping function. Time: 0.00378013
    [Stage 5] number of diffuse particles generated: 0 Time: 0.00223917
    [Stage 6] calculate diffuse particle positions. Time: 0.00201691
    [Stage 7] classify particles. Time: 8.59983e-06
    [Stage 8] Update particles! Time: 7.27735e-06
    [Stage 9] Delete particles! Deleted: 0 Time: 8.26865e-05
    [Stage 10] Append new particles! Total diffuse particles: 0

    *** Density ***
    Mean: -nan(ind)
    Min: 1.79769e+308
    Max: 2.22507e-308
    Min non-zero: 1.79769e+308

    [Stage 11] Save to file! Time: 0.230585

    Also here is a view of my simulation so it gives you an idea (dp 0.003)


    Have you any suggestion ?
    Thanks
  • Hi TPouzol,

    after two years, I have exactly the same issue: with official tutorial, Foam Calculator works well, but with a my own case (veri simple case) I have same result as you in 2019

    [Stage 10] Append new particles! Total diffuse particles: 0.

    Have been you able to run correctly your own case?

    If yes, can you help me?

    Bye, Piero

Sign In or Register to comment.