Skip to content

Commit 3f8b350

Browse files
hsalehipourmassimimApolo-ADSKnmorrisad
committed
Multi-res grid refinement + Neon backend support (#159)
* WIP * Single level working, multi-level runtime error: not enough resources * WIP: recursive * Refactoring. * WIP * Debugging * LDC * WIP * Improving GPU utilization. * Printing stats. * Printing stats. * Printing stats. * Printing stats. * Printing stats. * Cleaning. * Cleaning. * Fusion * Fusion * clean up and removing deprecated odd/even approach * added dGrid and mGrid handling in indices masker * Update test * Added a multires_boundary_masker and made sure results are correct. * Added KBC to the Neon backend * renamed some files and classes * added Neon backend to a couple BCs * converted missing mask from boolean to uint8 everywhere. * Heavily relying on existing warp functionals for the Neon backend of operators * added back post-collision apply_bc and the results are correct. * WIP: extrapolation outflow in Neon * added neon_apply_aux_recovery_bc, used center_index and more refactoring * Always using Warp backend when creating bc helper class to support Neon as well. * fixed a bug * Compelted Encoding/Decoding of BC aux data for ZouHe/Regularized for Multires * addressed PR review * Added capability to handle BC profiles in MRES * Reduced register pressure by avoiding reading f1_thread for all cells * fixed BC profile handling for Neon dense * The container should loop over all levels not the call to the container * no need to have separate functions for initializing and launching containers. Operator definition does that. * Simplified the multires simulation manager a lot by inheriting from MultiresStepper * Fixed a nasty bug! * no need to pass xlb_grid * Added padding to allow non cubic domains. * added a mesher utility function for multires * enabling mesh masker for multires cases * fixed the output order of cuboid mesher * Added a new example to showcase STL handling in MRES * stl handling in MRES working reasonably with 2 levels * parameterized problem 2 * No need for padding after Neon fix. Updated multi-res exampels. * Added new hybrid methods to handle stationary and moving boundaries. * Added hybridBC to the Neon backend and MultiRes settings * addressed PR review comments. * added a generic read and write method to further unify Warp and Neon backends * added store_dtype to neon backend * Added neon backend to AABB mesh masker using generic function calls. * added multires mesh masker (AABB). * Added moving boundary capability of halfway BC also to the JAX backend. * fixed couple emerging bugs in the JAX backend * Moved padding to BC class and improved the logic of indices masker in JAX * Changed indices masker WARP to rely on local write instead of remote write. Interior treatment is now consistent with JAX. * switched to generic read and write methods in indices masker to support both warp and neon * Added and used a helper function for boundary maskers * added read_field_neighbor and further unified neon and warp helpers in indices masker * made individual functionals for each kernel in indices masker * Converted indices masker to be launched over the entire grid and not just bc indices. This is needed for consistency with Neon and also mesh masker. * added a helper to check if a grid index matches a bc index * Added neon containers to indices masker. Working now but still lots of refactoring to be done. * WIP: added multi-res indice masker * WIP: Fixed a bug in multires indice masker and applied ruff formatting * Fixed a bug related to get global indices * Getting dtype from field using neon_get_dtype * deleted the old multires boundary masker * Ensuring other voxelization methods work for dense and raising error if chosen for multi-res * moved the computations of the momentum exchange to a functional and used read_field * moved the definition of streaming functional to construct warp * Added neon implementations of MomentumTransfer for dense and multires * Moved no-slip bc functional also outside to the warp and neon construct * fixed some operators default values * moved force to be a member of the class with a single pointer. Otherwise the pointers would be recreated at every launch and that was not captured properly by the neon implementation * minor todo items done * fixed force calculation for multires. Neon results seem to be non-deterministic! WIP: handling BC w/ distance! * Added the sphere example using the cuboid mesher * neon_get_type does not work. reverting back to hard-coded solution for now. * Added ExportMultiresHDF5 as a new class in mesher with Neon container implementation * Fixed issues with ExportMultiresHDF5. Outputs are now correct! * commented out bc_mask vtk export * fixed the fp64 issues * minor: updated rotating sphere example to use latest voxelization method * minor fix in other examples for fp64 * Added an OutletInitializer as a helper initializer class * replaced open3d with trimesh in all files and examples which gets rid of weird voxelization artifacts due to open3d * fixing CPU memory issue: merging duplicates in chucks * Generalized outlet initializer definition using bc_mask and made generic functional to handle both warp and neon * Added multires outlet initializer * Addressed PR review * Generalized the MRES IO class and added a new method to export a 2D image at an arbitrary slice * removed the redundant stl sphere example and corrected the sphere indices example. * Enabled auto chunking in the exporter * Fix: reducing memory usage on CPU for mres. * Perf: fusion at the finest level for mres. - OptimizationType class to manage different optimization for the mres LBM - Fused neon kernel for finest level of mres * Generalized the MultiresIO class to be used for any given field (not predefined fields) * Added a new method to multires grid class to enable extracting boundary indices across multiple levels. * cast to store dtype for any input type of mres IO * added remove_edges as an input arg to boundary_indices_across_levels * Fixed an error in cuboid mesher introduced in previous commits * fixed couple issues in MresIO class * addressed PR review comments * Refactoring: renaming DataUse to MemoryType * Debug: adding function to print neon grid information. * Fixed the IO culprit! * ruff changes * Enhancement: integrate neon skeleton with dGrid stepper * Added a minimal LBM stepper to the MomentumTransfer operator * Added force calculation to this example as well. * Applied the changes to multi-res. This enables generic handling of BCs in MRES. * Rename OptimizationType -> MresPerfOptimizationType * Add comment to multi-res grid. * Renaming related to mres perf. optimization type class. * Adding nvtx into requirements. * Uses only device memory for LBM population fields in Neon. Changes the memory type used for fields f_0 and f_1 to device memory only. * Updating to the latest Neon API. * fixed ruff formatting * minor refactoring * WIP: multi-GPU with Neon * Added force calculation to multires even when mesh distance is used. Only works with FUSION_AT_FINEST for now. * Fixed large memory usage in boundary_indices_across_levels * Refactoring mlups example * Refactoring mlups example * Refactoring mlups example * Refactoring mlups example * Add new command-line options for MLUPS simulation and enhance reporting features - Introduced options for generating reports, exporting final velocity fields, measuring scalability, and specifying the number of repetitions in the MLUPS simulation. - Updated argument parsing and output formatting to reflect new options. - Enhanced simulation summary and scalability analysis with detailed statistics and performance results. - Refactored simulation functions to accommodate new features and improve clarity. * Update MLUPS argument parsing and enhance OCC handling in NSE stepper - Modified command-line argument parsing for the MLUPS simulation to simplify occupancy options. - Updated the NSE stepper to validate and handle occupancy configuration more robustly. - Improved readability and clarity in the code by restructuring argument checks and adding comments. * fix xdmf path when saving in subfolder * MultiResIO updates * fixed ruff * improved the implementation of boundary data aux encoding during initialization * new aux encoder works with multires * added neon_index_to_warp to the bc helper * fixed a bug * Moved ZouHe/Regularized decoding function to the new EncodeAuxiliaryData helper class. * Major improvements to the handling of user-specified profiles in hybridBC * fixed bugs in ZouHe and Regularized after changes * HybridBC now working as expected with profiles * improved the logic a bit. needs more testing * minor change: not attributing the EncodeAuxiliaryData object to the BC object but rather using it as needed. * update(api): propagating API changes to mres code. * fix(extra): removing debug export operation for bc_mask. * style(ruff): running ruff * corrected interpolated bounceback method to achieve better results when applying hybridBC as inlet * refactoring(PR): applying changes base on the review from PR #18 * minor refactoring * enabled handling or user-defined profiles that span across multiple levels * This commit addresses the issue discussed in hsalehipour#20 * addressed PR review comments * Fixed the missing mask in MRES that was incorrect on +x, +y and +z bounds of the domain * Multi-res AABB close (#17) * Multi res AABB close neon impl, performs morpheological close operation on multi-res mesh and assigns boundary conditions appropriately * Support for multiple close voxels so larger gaps can be filled * Mesh voxelization method (#22) mesh_voxelization_method is callable now with optional input arguments. Also bc values are not hardcoded in multires macroscopic kernel. * Modified the OutletInitializer to be more customizable. Also added its JAX implementation. * refactor(mesher) : remove JAX dependency for warp and neon backends. Uses the `.numpy()` method directly for converting field warp data to NumPy arrays. This avoids the needs for JAX for the warp or neon backend. * Added multi-res RAY mesh masker (and Neon dense) * moved prepare skeleton to neon_launch and fixed occ none type in neon dense * added a util function to convert data in various backends to JAX for post-processing in single res. * added extrapolation outflow BC to Neon * updated wind tunnel example with Neon on multi-GPU * fixed the call to assemble_auxiliary_data for mres. * refactoring(perf-test): adding more options to the performance tests * refactoring(CLI): improving CLI for the performance tests refactoring(CLI): improving CLI for the performance tests * Omega must vary across resolutions to maintain viscosity as a constant * Added a utility class for unit conversion. * Added Ahmed benchmark example * refactoring(mres-stepper): new 'add_to_app' functionality Simplifies the `add_to_app` method in the multiresolution stepper. It now leverages keyword arguments and introspection for more flexible and maintainable operator calls. This change enhances code readability and reduces the risk of errors when adding new operators. * (feature) Two new optimization strategies for the mres stepper. * (refactoring) Removing debug IO * (refactoring) Applying ruff. * Function renaming. * Fixed a bug left from previous merge PR * The second moment computation includes "rho" embedded in its output. So no need to further multiply by rho in KBC. * Removed unused parameters (rho, u) from various collision methods, simplifying the function signatures across multiple classes. * Updared wall BC in this example to ensure numerical stability * Clean up (#34) * Fixed some runtime bugs * fixed some naming/spelling errors * removed some debugging comments. * Introduced a new file `cell_type.py` containing boundary-mask constants for fluid voxelss to replace hardcoded values with the new constants. * Applied renaming of 254 to SFV to function names * Refactoring to remove duplications. - Unified multi-resolution recursion builder in `simulation_manager.py` to streamline the construction of simulation steps. - Refactored nse_multires_stepper for improved clarity - Updated performance optimization handling in `multires_momentum_transfer.py` to support multiple fusion strategies. * Removed redundant functions from `nse_multires_stepper.py` to streamline and clarify the implementation of multi-resolution streaming steps. * Renamed functions in `nse_multires_stepper.py` for improved clarity. * Cleaning up multi-res stepper. * Documentation * Fixed mixed precision handling of the Neon backend for single-res and multi-res by ensuring consistent use of `store_dtype` and `compute_dtype`. * (refactoring) Allowing Warp backend to run without neon to be installed + README update (#39) * Ensuring all pytests are passing. * (install) extend XLB install for the Neon backend. (#40) * (build) Introducing Neon backend as an optional installation parameter. * (install) new installation mode for neon backend. * (build) Add ARM support for Neon wheel resolution * (documentation) Fixes to README and AUTHORS * (ruff) fixes to the style * (documentation) fix list of supported python versions * (install) Add installation unit tests for JAX, Warp and Neon backends (#41) * (build) Introducing Neon backend as an optional installation parameter. * (install) new installation mode for neon backend. * (build) Add ARM support for Neon wheel resolution * (documentation) Fixes to README and AUTHORS * (ruff) fixes to the style * (documentation) fix list of supported python versions * (install) Add installation unit tests for JAX, Warp and Neon backends, update utils for Warp to JAX conversion * (install) Enhance warp-lang uninstallation process for Neon installation (#42) * (build) Introducing Neon backend as an optional installation parameter. * (install) new installation mode for neon backend. * (build) Add ARM support for Neon wheel resolution * (documentation) Fixes to README and AUTHORS * (ruff) fixes to the style * (documentation) fix list of supported python versions * (install) Add installation unit tests for JAX, Warp and Neon backends, update utils for Warp to JAX conversion * (install) Enhance warp-lang uninstallation process for Neon installation - Updated `_uninstall_warp_lang` function to include a reason for uninstallation. - Modified `InstallWithNeonHooks` class to uninstall `warp-lang` before and after installation when the `[neon]` extra is requested. - Added a new test to verify that pre-existing `warp-lang` is uninstalled during the editable install of XLB with the `[neon]` extra. * (refactor) Update JSON data structure and clean up code (#43) * (build) Introducing Neon backend as an optional installation parameter. * (install) new installation mode for neon backend. * (build) Add ARM support for Neon wheel resolution * (documentation) Fixes to README and AUTHORS * (ruff) fixes to the style * (documentation) fix list of supported python versions * (install) Add installation unit tests for JAX, Warp and Neon backends, update utils for Warp to JAX conversion * (install) Enhance warp-lang uninstallation process for Neon installation - Updated `_uninstall_warp_lang` function to include a reason for uninstallation. - Modified `InstallWithNeonHooks` class to uninstall `warp-lang` before and after installation when the `[neon]` extra is requested. - Added a new test to verify that pre-existing `warp-lang` is uninstalled during the editable install of XLB with the `[neon]` extra. * (cleaning) removed unnecessary 'pass' call * (refactor) Update JSON data structure and clean up code - Modified the `ahmed.json` file to ensure consistent formatting of velocity and height data. - Removed a hardcoded comment in `multires_grid.py` regarding device initialization. - Commented out the `info_print` call in `neon_grid.py` to reduce output clutter. - Enhanced the `_create_constant_prescribed_profile` method in `bc_halfway_bounce_back.py` to better handle different compute backends and added error handling for unsupported backends. * Addressing multires PR review (#44) * added missing neon functionals and fixed forced_collision * fixed global coordinate calculations in NeonMultiresGrid for improved bounding box face detection across levels * Remove deprecated BC from README * fixed an issue in setting prescribed values in zouhe bc * Fixes to the PR comments (#45) * fix(install): add h5py when the neon installation option is selected. * refactor(mres): changed 'omega' to 'coalescence_factor' in function signatures. * refactor(grid): change default values of sparsity_pattern_list and sparsity_pattern_origins to None * fix(docs): correct typos in multires_flow_past_sphere_3d.py and update NEON backend description in compute_backend.py * ruff --------- Co-authored-by: massimim <57805133+massimim@users.noreply.github.com> --------- Co-authored-by: Massimiliano Meneghin <massimiliano.meneghin@autodesk.com> Co-authored-by: massimim <57805133+massimim@users.noreply.github.com> Co-authored-by: Apolo Vanderberg <apolo.vanderberg@autodesk.com> Co-authored-by: nmorrisad <nigel.morris@autodesk.com>
1 parent ec0f07e commit 3f8b350

92 files changed

Lines changed: 11577 additions & 1026 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,8 @@ venv/
131131
ENV/
132132
env.bak/
133133
venv.bak/
134+
.xlb-env/
135+
.xlb_install_test_venvs/
134136

135137
# Spyder project settings
136138
.spyderproject
@@ -155,11 +157,19 @@ checkpoints/*
155157
dist/
156158
build/
157159
*.egg-info/
160+
*.dot
161+
162+
# Ignore h5 and xmf formats
163+
*.h5
164+
*.xmf
165+
166+
# Ignore CSV files
167+
*.csv
158168

159169
# USD files
160170
*.usd
161171
*.usda
162172
*.usdc
163173
*.usd.gz
164174
*.usd.zip
165-
*.usd.bz2
175+
*.usd.bz2

AUTHORS

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,5 @@
55

66
Mehdi Ataei (Autodesk Inc)
77
Hesam Saleipour (Autodesk Inc)
8-
Oliver Hennigh (NVIDIA)
8+
Oliver Hennigh (NVIDIA)
9+
Massimiliano Meneghin (Autodesk Inc)

README.md

Lines changed: 66 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
# XLB: A Differentiable Massively Parallel Lattice Boltzmann Library in Python for Physics-Based Machine Learning
88

9-
XLB is a fully differentiable 2D/3D Lattice Boltzmann Method (LBM) library that leverages hardware acceleration. It supports [JAX](https://github.com/google/jax) and [NVIDIA Warp](https://github.com/NVIDIA/warp) backends, and is specifically designed to solve fluid dynamics problems in a computationally efficient and differentiable manner. Its unique combination of features positions it as an exceptionally suitable tool for applications in physics-based machine learning. With the new Warp backend, XLB now offers state-of-the-art performance for even faster simulations.
9+
XLB is a fully differentiable 2D/3D Lattice Boltzmann Method (LBM) library that leverages hardware acceleration. It supports [JAX](https://github.com/google/jax), [NVIDIA Warp](https://github.com/NVIDIA/warp), and [Neon](https://github.com/Autodesk/Neon) backends, and is specifically designed to solve fluid dynamics problems in a computationally efficient and differentiable manner. Its unique combination of features positions it as an exceptionally suitable tool for applications in physics-based machine learning. With the Warp backend, XLB offers state-of-the-art single-GPU performance, and with the new Neon backend it extends to multi-GPU (single-resolution). More importantly, the Neon backend provides grid refinement capabilities for multi-resolution simulations.
1010

1111
## Getting Started
1212
To get started with XLB, you can install it using pip. There are different installation options depending on your hardware and needs:
@@ -16,6 +16,12 @@ To get started with XLB, you can install it using pip. There are different insta
1616
pip install xlb
1717
```
1818

19+
### Installation with Warp support (single-GPU)
20+
For the NVIDIA Warp backend (single-GPU, state-of-the-art performance):
21+
```bash
22+
pip install "xlb[warp]"
23+
```
24+
1925
### Installation with CUDA support (for NVIDIA GPUs)
2026
This installation is for the JAX backend with CUDA support:
2127
```bash
@@ -28,9 +34,24 @@ This installation is for the JAX backend with TPU support:
2834
pip install "xlb[tpu]"
2935
```
3036

37+
### Installation with Neon support
38+
Neon backend enables multi-GPU dense and single-GPU multi-resolution representations.
39+
Install XLB with Neon support using:
40+
41+
```bash
42+
git clone https://github.com/Autodesk/XLB.git
43+
cd XLB
44+
pip install -r requirements.txt
45+
pip install '.[neon]'
46+
```
47+
48+
**Requirements:** The Neon wheel supports **Python 3.11** to **Python 3.14** on **Linux x86_64** and **Linux ARM**.
49+
50+
**Note:** Neon uses a custom fork of warp.
51+
3152
### Notes:
3253
- For Mac users: Use the basic CPU installation command as JAX's GPU support is not available on MacOS
33-
- The NVIDIA Warp backend is included in all installation options and supports CUDA automatically when available
54+
- Use `xlb[warp]` for the Warp backend (single-GPU) or `xlb[neon]` for the Neon backend (multi-GPU / multi-resolution). Do not install both in the same environment.
3455
- The installation options for CUDA and TPU only affect the JAX backend
3556

3657
To install the latest development version from source:
@@ -63,11 +84,36 @@ If you use XLB in your research, please cite the following paper:
6384
}
6485
```
6586

87+
If you use the grid refinement capabilities in your work, please also cite:
88+
89+
```
90+
@inproceedings{mahmoud2024optimized,
91+
title={Optimized {GPU} implementation of grid refinement in lattice {Boltzmann} method},
92+
author={Mahmoud, Ahmed H and Salehipour, Hesam and Meneghin, Massimiliano},
93+
booktitle={2024 IEEE International Parallel and Distributed Processing Symposium (IPDPS)},
94+
pages={398--407},
95+
year={2024},
96+
organization={IEEE}
97+
}
98+
99+
@inproceedings{meneghin2022neon,
100+
title={Neon: A Multi-{GPU} Programming Model for Grid-based Computations},
101+
author={Meneghin, Massimiliano and Mahmoud, Ahmed H. and Jayaraman, Pradeep Kumar and Morris, Nigel J. W.},
102+
booktitle={Proceedings of the 36th IEEE International Parallel and Distributed Processing Symposium},
103+
pages={817--827},
104+
year={2022},
105+
month={june},
106+
doi={10.1109/IPDPS53621.2022.00084},
107+
url={https://escholarship.org/uc/item/9fz7k633}
108+
}
109+
```
110+
66111
## Key Features
67-
- **Multiple Backend Support:** XLB now includes support for multiple backends including JAX and NVIDIA Warp, providing *state-of-the-art* performance for lattice Boltzmann simulations. Currently, only single GPU is supported for the Warp backend.
112+
- **Multiple Backend Support:** XLB includes support for JAX, NVIDIA Warp, and Neon backends, providing *state-of-the-art* performance for lattice Boltzmann simulations. The Warp backend targets single-GPU runs, while the Neon backend enables multi-GPU single-resolution and single-GPU multi-resolution simulations.
113+
- **Multi-Resolution Grid Refinement:** Mesh refinement with nested cuboid grids and multiple kernel-fusion strategies for optimal performance on the Neon backend.
68114
- **Integration with JAX Ecosystem:** The library can be easily integrated with JAX's robust ecosystem of machine learning libraries such as [Flax](https://github.com/google/flax), [Haiku](https://github.com/deepmind/dm-haiku), [Optax](https://github.com/deepmind/optax), and many more.
69115
- **Differentiable LBM Kernels:** XLB provides differentiable LBM kernels that can be used in differentiable physics and deep learning applications.
70-
- **Scalability:** XLB is capable of scaling on distributed multi-GPU systems using the JAX backend, enabling the execution of large-scale simulations on hundreds of GPUs with billions of cells.
116+
- **Scalability:** XLB is capable of scaling on distributed multi-GPU systems using the JAX backend or the Neon backend, enabling the execution of large-scale simulations on hundreds of GPUs with billions of cells.
71117
- **Support for Various LBM Boundary Conditions and Kernels:** XLB supports several LBM boundary conditions and collision kernels.
72118
- **User-Friendly Interface:** Written entirely in Python, XLB emphasizes a highly accessible interface that allows users to extend the library with ease and quickly set up and run new simulations.
73119
- **Leverages JAX Array and Shardmap:** The library incorporates the new JAX array unified array type and JAX shardmap, providing users with a numpy-like interface. This allows users to focus solely on the semantics, leaving performance optimizations to the compiler.
@@ -103,7 +149,7 @@ If you use XLB in your research, please cite the following paper:
103149
<img src="https://raw.githubusercontent.com/autodesk/xlb/main/assets/building.png" alt="" width="700">
104150
</p>
105151
<p align="center">
106-
Airflow in to, out of, and within a building (~400 million cells)
152+
Airflow into, out of, and within a building (~400 million cells)
107153
</p>
108154

109155
<p align="center">
@@ -128,6 +174,7 @@ The stages of a fluid density field from an initial state to the emergence of th
128174

129175
- BGK collision model (Standard LBM collision model)
130176
- KBC collision model (unconditionally stable for flows with high Reynolds number)
177+
- Smagorinsky LES sub-grid model for turbulence modelling
131178

132179
### Machine Learning
133180

@@ -143,21 +190,25 @@ The stages of a fluid density field from an initial state to the emergence of th
143190

144191
### Compute Capabilities
145192
- Single GPU support for the Warp backend with state-of-the-art performance
193+
- Multi-GPU support using the Neon backend with single-resolution grids
194+
- Grid refinement support on single-GPU using the Neon backend
146195
- Distributed Multi-GPU support using the JAX backend
147196
- Mixed-Precision support (store vs compute)
197+
- Multiple kernel-fusion performance strategies for multi-resolution simulations
148198
- Out-of-core support (coming soon)
149199

150200
### Output
151201

152202
- Binary and ASCII VTK output (based on PyVista library)
203+
- HDF5/XDMF output for multi-resolution data (with gzip compression)
153204
- In-situ rendering using [PhantomGaze](https://github.com/loliverhennigh/PhantomGaze) library
154205
- [Orbax](https://github.com/google/orbax)-based distributed asynchronous checkpointing
155-
- Image Output
206+
- Image Output (including multi-resolution slice images)
156207
- 3D mesh voxelizer using trimesh
157208

158209
### Boundary conditions
159210

160-
- **Equilibrium BC:** In this boundary condition, the fluid populations are assumed to be in at equilibrium. Can be used to set prescribed velocity or pressure.
211+
- **Equilibrium BC:** In this boundary condition, the fluid populations are assumed to be at equilibrium. Can be used to set prescribed velocity or pressure.
161212

162213
- **Full-Way Bounceback BC:** In this boundary condition, the velocity of the fluid populations is reflected back to the fluid side of the boundary, resulting in zero fluid velocity at the boundary.
163214

@@ -171,17 +222,20 @@ The stages of a fluid density field from an initial state to the emergence of th
171222

172223
- **Interpolated Bounceback BC:** Interpolated bounce-back boundary condition for representing curved boundaries.
173224

225+
- **Hybrid BC:** Combines regularized and bounce-back methods with optional wall-distance interpolation for improved accuracy on curved geometries.
226+
174227
## Roadmap
175228

176-
### Work in Progress (WIP)
177-
*Note: Some of the work-in-progress features can be found in the branches of the XLB repository. For contributions to these features, please reach out.*
229+
### Recently Completed
178230

179-
- 🌐 **Grid Refinement:** Implementing adaptive mesh refinement techniques for enhanced simulation accuracy.
231+
- **Grid Refinement:** Multi-resolution LBM with nested cuboid grids and multiple kernel-fusion strategies via the Neon backend.
180232

181-
- 💾 **Out-of-Core Computations:** Enabling simulations that exceed available GPU memory, suitable for CPU+GPU coherent memory models such as NVIDIA's Grace Superchips (coming soon).
233+
- **Multi-GPU Acceleration using [Neon](https://github.com/Autodesk/Neon) + Warp:** Multi-GPU support through Neon's data structures with Warp-based kernels for single-resolution settings.
182234

235+
### Work in Progress (WIP)
236+
*Note: Some of the work-in-progress features can be found in the branches of the XLB repository. For contributions to these features, please reach out.*
183237

184-
- **Multi-GPU Acceleration using [Neon](https://github.com/Autodesk/Neon) + Warp:** Using Neon's data structure for improved scaling.
238+
- 💾 **Out-of-Core Computations:** Enabling simulations that exceed available GPU memory, suitable for CPU+GPU coherent memory models such as NVIDIA's Grace Superchips (coming soon).
185239

186240
- 🗜️ **GPU Accelerated Lossless Compression and Decompression**: Implementing high-performance lossless compression and decompression techniques for larger-scale simulations and improved performance.
187241

examples/cfd/data/ahmed.json

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"_comment": "Ahmed Car Model, slant - angle = 25 degree. Profiles on symmetry plane (y=0) covering entire field. Origin of coordinate system: x=0: end of the car, y=0: symmetry plane, z=0: ground plane S.Becker/H. Lienhart/C Stoots, Institute of Fluid Mechanics, University Erlangen-Nuremberg, Erlangen, Germany, Coordinates in meters need to convert to voxels, Velocity data in m/s",
3+
"data": {
4+
"-1.162" : { "x-velocity" : [26.995,29.825,29.182,28.488,27.703,26.988,26.456,26.163,26.190,26.523,27.083,28.033,29.131,30.429,31.747,33.036,34.268,35.354,36.312,37.083,37.770,38.484,39.033,39.447,39.839,40.086,40.268,40.380,40.451], "height" : [0.028,0.048,0.068,0.088,0.108,0.128,0.148,0.168,0.188,0.208,0.228,0.248,0.268,0.288,0.308,0.328,0.348,0.368,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.7388]},
5+
"-1.062" : { "x-velocity" : [30.307,28.962,25.812,21.232,15.848,10.812,7.459,6.080,5.845,6.196,7.428,10.456,15.718,22.129,28.090,32.707,35.888,37.891,39.071,39.840,40.261,40.604,40.767,40.820,40.870,40.890,40.907,40.871,40.853], "height" : [0.028,0.048,0.068,0.088,0.108,0.128,0.148,0.168,0.188,0.208,0.228,0.248,0.268,0.288,0.308,0.328,0.348,0.368,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
6+
"-0.962" : { "x-velocity" : [52.216,51.303,50.196,48.833,47.728,46.790,45.514,44.222,43.379,42.829,42.322,42.056,41.876,41.706,41.584], "height" : [0.363,0.368,0.378,0.388,0.398,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
7+
"-0.862" : { "x-velocity" : [46.589,46.538,46.228,46.033,45.810,45.554,45.056,44.369,43.789,43.275,42.789,42.344,42.148,41.913,41.720], "height" : [0.363,0.368,0.378,0.388,0.398,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
8+
"-0.562" : { "x-velocity" : [43.237,43.262,43.248,43.225,43.183,43.145,43.083,43.030,42.904,42.776,42.685,42.434,42.358,42.197,42.042], "height" : [0.363,0.368,0.378,0.388,0.398,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
9+
"-0.362" : { "x-velocity" : [44.493,44.491,44.443,44.379,44.297,44.215,44.067,43.867,43.577,43.306,43.061,42.689,42.527,42.293,42.105], "height" : [0.363,0.368,0.378,0.388,0.398,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
10+
"-0.212" : { "x-velocity" : [49.202,48.429,47.805,46.697,45.883,44.913,44.195,43.650,43.130,42.677,42.432,42.154,41.961], "height" : [0.368,0.378,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
11+
"-0.162" : { "x-velocity" : [50.511,49.784,48.894,48.103,47.468,46.322,45.563,44.581,43.933,43.383,42.905,42.505,42.293,42.042,41.863], "height" : [0.348,0.358,0.368,0.378,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
12+
"-0.112" : { "x-velocity" : [27.615,35.449,41.526,46.068,46.277,46.038,45.774,45.505,45.237,44.701,44.326,43.765,43.284,42.890,42.529,42.247,42.082,41.880,41.732], "height" : [0.318,0.323,0.328,0.338,0.348,0.358,0.368,0.378,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
13+
"-0.062" : { "x-velocity" : [22.891,27.789,32.292,36.568,39.533,41.426,42.371,42.971,43.030,43.081,43.074,43.065,43.039,42.996,42.908,42.665,42.456,42.294,42.105,41.929,41.827,41.660,41.546], "height" : [0.298,0.303,0.308,0.313,0.318,0.323,0.328,0.338,0.348,0.358,0.368,0.378,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
14+
"-0.012" : { "x-velocity" : [23.304,26.317,29.429,32.341,34.923,37.106,38.673,39.841,40.447,40.780,40.973,41.085,41.193,41.282,41.359,41.442,41.522,41.699,41.737,41.749,41.724,41.714,41.642,41.574,41.518,41.431,41.366], "height" : [0.278,0.283,0.288,0.293,0.298,0.303,0.308,0.313,0.318,0.323,0.328,0.338,0.348,0.358,0.368,0.378,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
15+
"0.038" : { "x-velocity" : [42.752,37.392,15.320,-4.501,-8.079,-8.892,-8.420,-7.027,-5.143,-2.903,-0.936,0.927,2.200,3.099,3.622,4.026,4.280,4.520,5.620,8.938,13.913,17.872,21.148,24.814,29.075,33.188,36.424,38.490,39.388,39.675,39.794,39.911,40.007,40.219,40.425,40.643,40.757,40.896,40.994,41.058,41.124,41.127,41.143,41.106,41.080], "height" : [0.028,0.038,0.048,0.058,0.068,0.078,0.088,0.098,0.108,0.118,0.128,0.138,0.148,0.158,0.168,0.178,0.188,0.198,0.208,0.218,0.228,0.238,0.248,0.258,0.268,0.278,0.288,0.298,0.308,0.318,0.328,0.338,0.348,0.368,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
16+
"0.088" : { "x-velocity" : [41.859,35.830,22.660,7.745,-5.808,-12.650,-14.748,-13.756,-10.659,-6.484,-2.121,1.303,3.672,5.441,7.066,9.157,11.613,14.620,17.662,20.639,23.565,26.437,29.484,32.441,35.024,36.938,37.938,38.377,38.595,38.728,38.856,38.976,39.133,39.438,39.749,39.975,40.129,40.344,40.499,40.649,40.783,40.853,40.927,40.945,40.960], "height" : [0.028,0.038,0.048,0.058,0.068,0.078,0.088,0.098,0.108,0.118,0.128,0.138,0.148,0.158,0.168,0.178,0.188,0.198,0.208,0.218,0.228,0.238,0.248,0.258,0.268,0.278,0.288,0.298,0.308,0.318,0.328,0.338,0.348,0.368,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
17+
"0.138" : { "x-velocity" : [36.223,32.501,24.752,14.281,2.799,-6.218,-10.908,-11.892,-9.708,-5.258,-0.140,4.331,7.882,10.995,13.961,16.699,19.477,22.063,24.651,27.081,29.524,31.950,34.043,35.594,36.506,37.053,37.386,37.614,37.832,38.032,38.214,38.397,38.575,38.940,39.298,39.533,39.749,40.028,40.206,40.404,40.580,40.691,40.803,40.858,40.921], "height" : [0.028,0.038,0.048,0.058,0.068,0.078,0.088,0.098,0.108,0.118,0.128,0.138,0.148,0.158,0.168,0.178,0.188,0.198,0.208,0.218,0.228,0.238,0.248,0.258,0.268,0.278,0.288,0.298,0.308,0.318,0.328,0.338,0.348,0.368,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
18+
"0.188" : { "x-velocity" : [29.417,27.755,23.967,18.261,11.662,5.405,0.676,-0.652,0.937,4.261,7.958,11.427,14.366,17.138,19.735,22.151,24.577,26.883,29.165,31.111,32.781,34.072,34.893,35.524,35.974,36.329,36.604,36.872,37.138,37.402,37.673,37.900,38.112,38.518,38.829,39.088,39.326,39.639,39.871,40.096,40.275,40.423,40.523,40.603,40.687], "height" : [0.028,0.038,0.048,0.058,0.068,0.078,0.088,0.098,0.108,0.118,0.128,0.138,0.148,0.158,0.168,0.178,0.188,0.198,0.208,0.218,0.228,0.238,0.248,0.258,0.268,0.278,0.288,0.298,0.308,0.318,0.328,0.338,0.348,0.368,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
19+
"0.238" : { "x-velocity" : [24.405,24.168,22.782,20.196,16.970,13.937,12.137,11.757,12.851,14.649,16.780,18.995,21.070,23.335,25.280,27.468,29.262,30.832,32.133,33.102,33.856,34.473,34.922,35.340,35.698,36.039,36.336,36.629,36.906,37.193,37.454,37.691,37.929,38.329,38.611,38.875,39.126,39.414,39.677,39.917,40.097,40.259,40.380,40.478,40.568], "height" : [0.028,0.038,0.048,0.058,0.068,0.078,0.088,0.098,0.108,0.118,0.128,0.138,0.148,0.158,0.168,0.178,0.188,0.198,0.208,0.218,0.228,0.238,0.248,0.258,0.268,0.278,0.288,0.298,0.308,0.318,0.328,0.338,0.348,0.368,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]},
20+
"0.288" : { "x-velocity" : [21.489,22.225,22.127,21.456,20.404,19.743,19.541,19.909,21.002,22.381,24.018,25.670,27.421,28.998,30.371,31.523,32.406,33.111,33.670,34.155,34.532,34.893,35.240,35.567,35.875,36.158,36.437,36.708,36.974,37.230,37.473,37.709,37.932,38.266,38.515,38.773,39.008,39.270,39.562,39.782,39.962,40.148,40.266,40.369,40.475], "height" : [0.028,0.038,0.048,0.058,0.068,0.078,0.088,0.098,0.108,0.118,0.128,0.138,0.148,0.158,0.168,0.178,0.188,0.198,0.208,0.218,0.228,0.238,0.248,0.258,0.268,0.278,0.288,0.298,0.308,0.318,0.328,0.338,0.348,0.368,0.388,0.408,0.428,0.458,0.488,0.518,0.558,0.598,0.638,0.688,0.738]}
21+
}
22+
}

0 commit comments

Comments
 (0)