svFSIplus: Text file containing results empty

Provides a system for patient-specific cardiovascular modeling and simulation.
POST REPLY
User avatar
Amit Raj
Posts: 8
Joined: Sat Jun 15, 2024 3:39 am

svFSIplus: Text file containing results empty

Post by Amit Raj » Sat Dec 07, 2024 10:10 am

Hello!

I am running svFSIplus by pulling it using Singularity on an HPC cluster. When I run any simulation from the cases provided in the svFSIplus repository, the results are generated in the procs folder. However, the text files within the procs folder, "B_NS_Pressure", "B_NS_Velocity_flux", and "B_NS_WSS", remain empty and do not update with timesteps. Could you please help me understand what is causing these text files to be empty and how I can resolve this issue?

Thank you in advance!!!

User avatar
David Parker
Posts: 1760
Joined: Tue Aug 23, 2005 2:43 pm

Re: svFSIplus: Text file containing results empty

Post by David Parker » Sat Dec 07, 2024 2:55 pm

Hello,

This is a bug we just discovered (see https://github.com/SimVascular/svMultiP ... issues/309), will try to get a fix for it next week.

Cheers,
Dave

User avatar
Amit Raj
Posts: 8
Joined: Sat Jun 15, 2024 3:39 am

Re: svFSIplus: Text file containing results empty

Post by Amit Raj » Sun Dec 08, 2024 4:10 am

Thank you for responding!
I am running CFD & FSI simulation for coronary normal case. I want to analyze the results at the inlet, wall, all the outlets, and any cross-section across the lumen. To do this, I need to align a slice perpendicular to the lumen. However, it is challenging to align the slice perpendicular to the lumen in ParaView considering the curved path of arteries. Could you please guide me on how to do this?

User avatar
David Parker
Posts: 1760
Joined: Tue Aug 23, 2005 2:43 pm

Re: svFSIplus: Text file containing results empty

Post by David Parker » Mon Dec 09, 2024 6:40 pm

Hello,

You can use centerline geometry to align slices along a vessel. Centerlines can be computed using the SV Modeler Tool or using the SV Python API (see https://simvascular.github.io/documenta ... mtk_module).

However, I don't know how to use centerlines geometry to position a slice plane in ParaView. You might need to write a Python script using vtk to do this. Have a look at https://github.com/ktbolt/cardiovascula ... nes/python. This is an old code that may not work but it should give you an idea about how to extract a slice using centerline data.

Cheers,
Dave

User avatar
Amit Raj
Posts: 8
Joined: Sat Jun 15, 2024 3:39 am

Re: svFSIplus: Text file containing results empty

Post by Amit Raj » Thu Jan 09, 2025 1:53 am

Hello,
Now, after updating boundary integral script in xml file I successfuly able to write result in .txt file for fluid and cmm simulation. For FSI simulation, in ALE case, after writing this script in xml file I got error during simulation in timestep 1 itself and simulation stopped. what could be issue? Thanks

Code: Select all

---------------------------------------------------------------------
 Eq     N-i     T       dB  Ri/R1   Ri/R0    R/Ri     lsIt   dB  %t
---------------------------------------------------------------------
 FS 1-1  6.694e+01  [0 1.000e+00 1.000e+00 9.992e-05]  [3450 -1 91]
 MS 1-1  6.780e+01  [0 1.000e+00 1.000e+00 9.975e-05]  [59 -1 37]
 FS 1-2  1.709e+02  [-71 2.663e-04 2.663e-04 9.996e-05]  [5495 -1 94]
 MS 1-2  1.727e+02  [-55 1.664e-03 1.664e-03 9.509e-05]  [220 -1 69]
 FS 1-3  2.604e+02  [-130 3.083e-07 3.083e-07 9.982e-05]  [4627 -1 93]
free(): double free detected in tcache 2
[cn012:08877] *** Process received signal ***
[cn012:08877] Signal: Aborted (6)
[cn012:08877] Signal code:  (1)
[cn012:08877] [ 0] /lib/x86_64-linux-gnu/libc.so.6(+0x42520)[0x2b5dcdd7b520]
[cn012:08877] [ 1] /lib/x86_64-linux-gnu/libc.so.6(pthread_kill+0x12c)[0x2b5dcddcf9fc]
[cn012:08877] [ 2] /lib/x86_64-linux-gnu/libc.so.6(raise+0x16)[0x2b5dcdd7b476]
[cn012:08877] [ 3] /lib/x86_64-linux-gnu/libc.so.6(abort+0xd3)[0x2b5dcdd617f3]
[cn012:08877] [ 4] /lib/x86_64-linux-gnu/libc.so.6(+0x89676)[0x2b5dcddc2676]
[cn012:08877] [ 5] /lib/x86_64-linux-gnu/libc.so.6(+0xa0cfc)[0x2b5dcddd9cfc]
[cn012:08877] [ 6] /lib/x86_64-linux-gnu/libc.so.6(+0xa30ab)[0x2b5dcdddc0ab]
[cn012:08877] [ 7] /lib/x86_64-linux-gnu/libc.so.6(free+0x73)[0x2b5dcddde453]
[cn012:08877] [ 8] /lib/x86_64-linux-gnu/libc.so.6(_IO_fclose+0xb7)[0x2b5dcddb7d27]
[cn012:08877] [ 9] /build-trilinos/svMultiPhysics-build/bin/svmultiphysics(_ZN6txt_ns28write_boundary_integral_dataERK6ComModR5CmModRK6eqTypeiNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERK5ArrayIdEbb+0x223)[0x55a6b179a503]
[cn012:08877] [10] /build-trilinos/svMultiPhysics-build/bin/svmultiphysics(_ZN6txt_ns3txtEP10Simulationb+0xf93)[0x55a6b179b6d3]
[cn012:08877] [11] /build-trilinos/svMultiPhysics-build/bin/svmultiphysics(_Z16iterate_solutionP10Simulation+0x25fe)[0x55a6b16c590e]
[cn012:08877] [12] /build-trilinos/svMultiPhysics-build/bin/svmultiphysics(main+0x23c)[0x55a6b15c593c]
[cn012:08877] [13] /lib/x86_64-linux-gnu/libc.so.6(+0x29d90)[0x2b5dcdd62d90]
[cn012:08877] [14] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x80)[0x2b5dcdd62e40]
[cn012:08877] [15] /build-trilinos/svMultiPhysics-build/bin/svmultiphysics(_start+0x25)[0x55a6b15ed705]
[cn012:08877] *** End of error message ***
--------------------------------------------------------------------------
prterun noticed that process rank 0 with PID 8877 on node cn012 exited on
signal 6 (Aborted).

User avatar
David Parker
Posts: 1760
Joined: Tue Aug 23, 2005 2:43 pm

Re: svFSIplus: Text file containing results empty

Post by David Parker » Thu Jan 09, 2025 11:29 am

Hello,

I don't understand what you mean by updating boundary integral script in xml file.

You are running an FSI simulation using ALE and it is failing? Please post your solver input XML file so I can understand what your problem is.

Cheers,
Dave

User avatar
Amit Raj
Posts: 8
Joined: Sat Jun 15, 2024 3:39 am

Re: svFSIplus: Text file containing results empty

Post by Amit Raj » Thu Jan 09, 2025 9:30 pm

Yes, my ALE simulation getting stopped.

Updating boundary integral script in XML file means I am writing to find "B_INT" of pressure, velocity and WSS.

One more thing, here I have used fsils preconditioner so simulation running fine when I am changing it to trilinos simulation getting stopped after few iteration. what could be problem for that?

Below is the XML file script & you can see error I am getting in my last reply:

Code: Select all

<?xml version="1.0" encoding="UTF-8" ?>
<svMultiPhysicsFile version="0.1">

<GeneralSimulationParameters>
  <Continue_previous_simulation> 0 </Continue_previous_simulation>
  <Number_of_spatial_dimensions> 3 </Number_of_spatial_dimensions>
  <Number_of_time_steps> 3000 </Number_of_time_steps>
  <Time_step_size> 0.001 </Time_step_size>
  <Spectral_radius_of_infinite_time_step> 0.50 </Spectral_radius_of_infinite_time_step>
  <Searched_file_name_to_trigger_stop> STOP_SIM </Searched_file_name_to_trigger_stop>
  <Save_results_to_VTK_format> true </Save_results_to_VTK_format>
  <Name_prefix_of_saved_VTK_files> result </Name_prefix_of_saved_VTK_files>
  <Increment_in_saving_VTK_files> 100 </Increment_in_saving_VTK_files>
  <Start_saving_after_time_step> 1 </Start_saving_after_time_step>
  <Increment_in_saving_restart_files> 100 </Increment_in_saving_restart_files>
  <Convert_BIN_to_VTK_format> 0 </Convert_BIN_to_VTK_format>
  <Verbose> 1 </Verbose>
  <Warning> 0 </Warning>
  <Debug> 0 </Debug>
</GeneralSimulationParameters>

<Add_mesh name="lumen" >
  <Mesh_file_path> mesh/lumen/mesh-complete.mesh.vtu  </Mesh_file_path>
  <Add_face name="lumen-inflow">
      <Face_file_path> mesh/lumen/mesh-surfaces/lumen-inflow.vtp </Face_file_path>
          </Add_face>
          <Add_face name="lumen-wall">
      <Face_file_path> mesh/lumen/mesh-surfaces/lumen-wall.vtp </Face_file_path>
  </Add_face>
  <Add_face name="lumen-outflow">
      <Face_file_path> mesh/lumen/mesh-surfaces/lumen-outflow.vtp </Face_file_path>
          </Add_face>
   <Add_face name="lumen-btrunk">
      <Face_file_path> mesh/lumen/mesh-surfaces/lumen-btrunk.vtp </Face_file_path>
          </Add_face>
   <Add_face name="lumen-rt_carotid">
      <Face_file_path> mesh/lumen/mesh-surfaces/lumen-rt_carotid.vtp </Face_file_path>
          </Add_face>
          <Add_face name="lumen-carotid">
      <Face_file_path> mesh/lumen/mesh-surfaces/lumen-carotid.vtp </Face_file_path>
          </Add_face>
          <Add_face name="lumen-subclavian">
      <Face_file_path> mesh/lumen/mesh-surfaces/lumen-subclavian.vtp </Face_file_path>
          </Add_face>
          <Domain> 0 </Domain>
</Add_mesh>

<Add_mesh name="wall" >
  <Mesh_file_path> mesh/wall/mesh-complete.mesh.vtu  </Mesh_file_path>
  <Add_face name="wall-inflow">
      <Face_file_path> mesh/wall/mesh-surfaces/wall-inflow.vtp </Face_file_path>
  </Add_face>
  <Add_face name="wall-outflow">
      <Face_file_path> mesh/wall/mesh-surfaces/wall-outflow.vtp </Face_file_path>
  </Add_face>
  <Add_face name="wall-btrunk">
      <Face_file_path> mesh/wall/mesh-surfaces/wall-btrunk.vtp </Face_file_path>
  </Add_face>
  <Add_face name="wall-rt_carotid">
      <Face_file_path> mesh/wall/mesh-surfaces/wall-rt_carotid.vtp </Face_file_path>
  </Add_face>
  <Add_face name="wall-carotid">
      <Face_file_path> mesh/wall/mesh-surfaces/wall-carotid.vtp </Face_file_path>
  </Add_face>
  <Add_face name="wall-inner">
      <Face_file_path> mesh/wall/mesh-surfaces/wall-inner.vtp </Face_file_path>
  </Add_face>
  <Add_face name="wall-outer">
      <Face_file_path> mesh/wall/mesh-surfaces/wall-outer.vtp </Face_file_path>
  </Add_face>
  <Add_face name="wall-subclavian">
      <Face_file_path> mesh/wall/mesh-surfaces/wall-subclavian.vtp </Face_file_path>
  </Add_face>
  <Domain> 1 </Domain>
</Add_mesh>

<Add_projection name="wall-inner" >
   <Project_from_face> lumen-wall </Project_from_face>
</Add_projection>

<Add_equation type="FSI" >
   <Coupled> true </Coupled>
   <Min_iterations> 1 </Min_iterations>
   <Max_iterations> 10 </Max_iterations>
   <Tolerance> 1e-4 </Tolerance>

   <Domain id="0" >
      <Equation> fluid </Equation>
      <Density> 1.0 </Density>
      <Viscosity model="Constant" >
         <Value> 0.04 </Value>
      </Viscosity>
      <Backflow_stabilization_coefficient> 0.2 </Backflow_stabilization_coefficient>
   </Domain>

   <Domain id="1" >
      <Equation> struct </Equation>
      <Constitutive_model type="neoHookean"> </Constitutive_model>
      <Dilational_penalty_model> M94 </Dilational_penalty_model>
      <Density> 1.0 </Density>
      <Elasticity_modulus> 1.0e7 </Elasticity_modulus>
      <Poisson_ratio> 0.3 </Poisson_ratio>
   </Domain>

   <LS type="GMRES" >
      <Linear_algebra type="fsils" >
         <Preconditioner> fsils </Preconditioner>
      </Linear_algebra>
      <Tolerance> 1e-4 </Tolerance>
      <Max_iterations> 500 </Max_iterations>
      <Krylov_space_dimension> 50 </Krylov_space_dimension>
   </LS>

   <Output type="Spatial" >
     <Displacement> true </Displacement>
     <Velocity> true </Velocity>
     <Pressure> true </Pressure>
     <VonMises_stress> true </VonMises_stress>
   </Output>

   <Output type="Alias" >
       <Displacement> FS_Displacement </Displacement>
   </Output>

     <Output type="B_INT" >
     <Pressure> true </Pressure>
     <Velocity> true </Velocity>
     <WSS> true </WSS>
     </Output>

   <Add_BC name="lumen-inflow" >
      <Type> Dir </Type>
      <Time_dependence> Unsteady </Time_dependence>
          <Temporal_values_file_path> lumen_inlet.flow </Temporal_values_file_path>
          <Profile> Parabolic </Profile>
          <Impose_flux> true </Impose_flux>
   </Add_BC>

    <Add_BC name="lumen-outflow" >
      <Type> Neu </Type>
      <Time_dependence> RCR </Time_dependence>
      <RCR_values>
         <Proximal_resistance> 274.0 </Proximal_resistance>
         <Capacitance> 0.000354000 </Capacitance>
         <Distal_resistance> 3639.0 </Distal_resistance>
        <Distal_pressure> 0.0 </Distal_pressure>
        <Initial_pressure> 0 </Initial_pressure>
      </RCR_values>
          </Add_BC>

          <Add_BC name="lumen-btrunk" >
      <Type> Neu </Type>
      <Time_dependence> RCR </Time_dependence>
      <RCR_values>
         <Proximal_resistance> 1510.0 </Proximal_resistance>
         <Capacitance> 6.42e-5 </Capacitance>
         <Distal_resistance> 20064.0 </Distal_resistance>
         <Distal_pressure> 0.0 </Distal_pressure>
         <Initial_pressure> 0 </Initial_pressure>
      </RCR_values>
         </Add_BC>

          <Add_BC name="lumen-carotid" >
      <Type> Neu </Type>
      <Time_dependence> RCR </Time_dependence>
      <RCR_values>
         <Proximal_resistance> 1836.0 </Proximal_resistance>
         <Capacitance> 5.658e-5 </Capacitance>
         <Distal_resistance> 22644.0 </Distal_resistance>
         <Distal_pressure> 0.0 </Distal_pressure>
         <Initial_pressure> 0 </Initial_pressure>
      </RCR_values>
           </Add_BC>

          <Add_BC name="lumen-rt_carotid" >
      <Type> Neu </Type>
      <Time_dependence> RCR </Time_dependence>
      <RCR_values>
         <Proximal_resistance> 1714.0 </Proximal_resistance>
         <Capacitance> 5.658e-5 </Capacitance>
         <Distal_resistance> 22766.0 </Distal_resistance>
         <Distal_pressure> 0.0 </Distal_pressure>
         <Initial_pressure> 0 </Initial_pressure>
      </RCR_values>
         </Add_BC>

          <Add_BC name="lumen-subclavian" >
      <Type> Neu </Type>
      <Time_dependence> RCR </Time_dependence>
      <RCR_values>
         <Proximal_resistance> 1513.0 </Proximal_resistance>
         <Capacitance> 6.864e-5</Capacitance>
         <Distal_resistance> 18665.0 </Distal_resistance>
         <Distal_pressure> 0.0 </Distal_pressure>
         <Initial_pressure> 0 </Initial_pressure>
      </RCR_values>
      </Add_BC>

   <Add_BC name="wall-inflow" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
      <Impose_on_state_variable_integral> true </Impose_on_state_variable_integral>
   </Add_BC>

   <Add_BC name="wall-outflow" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
      <Impose_on_state_variable_integral> true </Impose_on_state_variable_integral>
   </Add_BC>

   <Add_BC name="wall-btrunk" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
      <Impose_on_state_variable_integral> true </Impose_on_state_variable_integral>
   </Add_BC>

   <Add_BC name="wall-rt_carotid" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
      <Impose_on_state_variable_integral> true </Impose_on_state_variable_integral>
   </Add_BC>

   <Add_BC name="wall-carotid" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
      <Impose_on_state_variable_integral> true </Impose_on_state_variable_integral>
   </Add_BC>

   <Add_BC name="wall-subclavian" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
      <Impose_on_state_variable_integral> true </Impose_on_state_variable_integral>
   </Add_BC>

</Add_equation>


<Add_equation type="mesh" >
   <Coupled> true </Coupled>
   <Min_iterations> 1 </Min_iterations>
   <Max_iterations> 7 </Max_iterations>
   <Tolerance> 1e-4 </Tolerance>
   <Poisson_ratio> 0.3 </Poisson_ratio>

   <LS type="CG" >
      <Linear_algebra type="fsils" >
         <Preconditioner> fsils </Preconditioner>
      </Linear_algebra>
      <Tolerance> 1e-4 </Tolerance>
   </LS>

   <Output type="Spatial" >
     <Displacement> true </Displacement>
   </Output>

   <Add_BC name="lumen-inflow" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
   </Add_BC>

   <Add_BC name="lumen-outflow" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
   </Add_BC>

   <Add_BC name="lumen-btrunk" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
   </Add_BC>

   <Add_BC name="lumen-rt_carotid" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
   </Add_BC>

   <Add_BC name="lumen-carotid" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
   </Add_BC>

   <Add_BC name="lumen-subclavian" >
      <Type> Dir </Type>
      <Value> 0.0 </Value>
   </Add_BC>

</Add_equation>

</svMultiPhysicsFile>


User avatar
David Parker
Posts: 1760
Joined: Tue Aug 23, 2005 2:43 pm

Re: svFSIplus: Text file containing results empty

Post by David Parker » Fri Jan 10, 2025 2:28 pm

Hello,

The script you showed above does not use Trilinos.

What do you mean when you say trilinos simulation getting stopped ? Do you mean the simulation is failing ? Is this the error you showed above

Code: Select all

free(): double free detected in tcache 2
[cn012:08877] *** Process received signal ***
[cn012:08877] Signal: Aborted (6)
[cn012:08877] Signal code: (1)
Cheers,
Dave

User avatar
Amit Raj
Posts: 8
Joined: Sat Jun 15, 2024 3:39 am

Re: svFSIplus: Text file containing results empty

Post by Amit Raj » Sat Jan 11, 2025 6:04 am

No, the error you mentioned is when I wrote B_INT in XML script. Please let me know how to rectify this, I needed to write boundary integrals at outlets in txt file.

When I am using trilinos preconditioner, my simulation is failing and error coming is:

Code: Select all

---------------------------------------------------------------------
 Eq     N-i     T       dB  Ri/R1   Ri/R0    R/Ri     lsIt   dB  %t
---------------------------------------------------------------------
 FS 1-1  2.318e+01  [0 1.000e+00 1.000e+00 9.329e-05]  [99 -34 83]
 MS 1-1  2.560e+01  [0 1.000e+00 1.000e+00 5.540e-05]  [8 -98 56]
 FS 1-2  6.381e+01  [-70 2.959e-04 2.959e-04 9.787e-05]  [165 -4 90]
 MS 1-2  7.249e+01  [-57 1.406e-03 1.406e-03 5.234e-05]  [48 -99 87]
 FS 1-3  8.837e+01  [-75 1.657e-04 1.657e-04 9.691e-05]  [58 -1 75]
 MS 1-3  9.426e+01  [-105 5.416e-06 5.416e-06 9.352e-05]  [30 -93 80]
 FS 1-4  1.114e+02  [-82 7.657e-05 7.657e-05 9.905e-05]  [65 -2 77]
terminate called after throwing an instance of 'std::runtime_error'
  what():  [set_bc_cpl]  Follower pressure load must be used for 0D coupling with struct/ustruct
[login01:69692] *** Process received signal ***
[login01:69692] Signal: Aborted (6)
[login01:69692] Signal code: User function (kill, sigsend, abort, etc.) (0)
terminate called after throwing an instance of 'std::runtime_error'
  what():  [set_bc_cpl]  Follower pressure load must be used for 0D coupling with struct/ustruct
[login01:69690] *** Process received signal ***
[login01:69690] Signal: Aborted (6)
[login01:69690] Signal code: User function (kill, sigsend, abort, etc.) (0)
terminate called after throwing an instance of 'std::runtime_error'
  what():  [set_bc_cpl]  Follower pressure load must be used for 0D coupling with struct/ustruct
[login01:69689] *** Process received signal ***
[login01:69689] Signal: Aborted (6)

POST REPLY