XLB icon indicating copy to clipboard operation
XLB copied to clipboard

FullwayBounceBack BC registered but not simulated in flow past sphere example

Open PassengerC07 opened this issue 1 year ago • 2 comments

Using the flow past sphere example.

The following lines were changed:

# bc_left = RegularizedBC("velocity", profile=bc_profile(), indices=inlet)
bc_left = RegularizedBC("velocity", prescribed_value=(u_max, 0.0, 0.0), indices=inlet)
bc_sphere = FullwayBounceBackBC(indices=sphere)

Also the FullwayBounceBackBC on the sphere is registered in simulation setup:

Warp 1.6.2 initialized:
   CUDA Toolkit 12.8, Driver 12.0
   Devices:
     "cpu"      : "x86_64"
     "cuda:0"   : "NVIDIA RTX A2000 12GB" (12 GiB, sm_86, mempool enabled)
   Kernel cache:
     /home/z004ky4k/.cache/warp/1.6.2
registered bc RegularizedBC_8761954115455 with id 1
registered bc FullwayBounceBackBC_8761954115452 with id 2
registered bc ExtrapolationOutflowBC_8761932727447 with id 3
registered bc FullwayBounceBackBC_8761932743056 with id 4
Module xlb.operator.equilibrium.quadratic_equilibrium a7e63a8 load on device 'cuda:0' took 1.21 ms  (cached)
Module xlb.operator.boundary_masker.indices_boundary_masker ba1bde6 load on device 'cuda:0' took 1.24 ms  (cached)
Module xlb.operator.boundary_condition.boundary_condition d038e91 load on device 'cuda:0' took 1.37 ms  (cached)
Module xlb.operator.stepper.nse_stepper 52f7e03 load on device 'cuda:0' took 15.50 ms  (cached)

XLB 0.2.1 installed from src with pip.

The results show that the sphere is not simulated:

Image

Image

Versus HalfwayBounceBackBC (only change this one line):

Image

PassengerC07 avatar May 15 '25 03:05 PassengerC07

Could you please clean the Warp cache and try again? Delete home/z004ky4k/.cache/warp/1.6.2 folder.

mehdiataei avatar May 15 '25 15:05 mehdiataei

Could you please clean the Warp cache and try again? Delete home/z004ky4k/.cache/warp/1.6.2 folder.

This fixes the issue. Do we need to regenerate the Warp cache everytime we run a simulation?

PassengerC07 avatar May 19 '25 05:05 PassengerC07

@PassengerC07 it's a Warp specific issue not XLB. I have faced it before but couldn't reproduce it. If you can create a reproduction of this issue step by step we can raise the issue with NVIDIA to fix it.

mehdiataei avatar May 20 '25 23:05 mehdiataei

@PassengerC07 it's a Warp specific issue not XLB. I have faced it before but couldn't reproduce it. If you can create a reproduction of this issue step by step we can raise the issue with NVIDIA to fix it.

I'm afraid I cannot reproduce it either. I had run multiple cases before doing the comparison above and can't really tell which cases caused this issue.

PassengerC07 avatar May 21 '25 02:05 PassengerC07