Novel distance-based masking and adaptive α-shape methods for CNN-ready reconstruction of arbitrary 2D CFD flow domains
Interpolating scattered CFD datasets onto a uniform Cartesian grid can distort the true geometry, producing a convex-hull type envelope and activating nonphysical regions. This work presents a reconstruction framework that accurately recovers the true geometric boundaries of arbitrary computational domains before exporting CNN-ready fields. It introduces two novel strategies, distance-based masking and an adaptive α -shape formulation that normalizes α using local data resolution, and evaluates them against classical α -shape boundary recovery. A quantitative, topology-aware metric suite is introduced to assess retention, suppression of unsupported regions, overlap consistency, and connectivity. The novel distance-based method is robust across the geometries considered under the same threshold rule, with τ set to the minimum CFD grid spacing, and achieves 4.3 × − 19.3 × speedups over classical α -shapes. The adaptive α -shape remains stable when its control parameter is set to 1 and is 2.1 × − 3.9 × faster than the classical variant, which requires geometry-specific α tuning. A lightweight boundary inflation post-process using a minimal dilation further improves retention by up to 3.05 % with negligible unsupported activation ( ≤ 0.08 % ). Overall, the distance-based method is recommended as the default due to its accuracy, stability, minimal tuning, and low cost, while the adaptive α -shape is a strong alternative when grid-spacing information for threshold selection is unavailable. The proposed framework is intended as a preprocessing step for CNN-based CFD workflows. A companion web application operationalizes the workflow end-to-end, enabling 2D ASCII dataset upload, parameter tuning, mask and boundary generation, and export of CNN-ready outputs.
Authors
- Gorka S. Larraona (ORCID: https://orcid.org/0000-0001-9055-4995)
- Alejandro Rivas (ORCID: https://orcid.org/0000-0001-7755-8748)
- Mehran Sharifi (ORCID: https://orcid.org/0009-0007-7007-4549)
Institutions
- Universidad de Navarra (ES)
Publication Details
- Journal
- Advances in Engineering Software
- Published
- 2026-11-26
- DOI
- https://doi.org/10.1016/j.advengsoft.2026.104346
- Citations
- 3
- Primary Topic
- Computational Geometry and Mesh Generation
- Type
- article
- Field-Weighted Citation Impact
- 3.76