Aerodynamic design method and system based on hierarchical flow matching and simulation-driven fine-tuning
The aerodynamic design system, which combines hierarchical flow matching and simulation-driven fine-tuning, solves the problems of component-level semantic constraints and aerodynamic condition control in 3D generation methods. It achieves component-level semantic perception and fine control of aerodynamic performance, thereby improving generation efficiency and performance compliance rate.
Patent Information
- Application Number
- CN202611585312.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-10-14
- Publication Date
- 2026-11-10
AI Technical Summary
Existing 3D generation methods lack component-level semantic constraints, resulting in unstable boundaries and relative positions of components such as fuselage, wings, and tail, making it difficult to directly incorporate them into aerodynamic evaluation. Furthermore, the influence of multi-parameter design conditions is difficult to distinguish, and there is a lack of feedback update mechanisms between the generated model and the physical simulation solver, leading to mutual constraints among optimization objectives.
An aerodynamic design system employing hierarchical flow matching and simulation-driven fine-tuning achieves component semantic perception and fine-tuning of aerodynamic conditions through a semantic voxel autoregression generation module, a conditional SLAT flow matching fine geometry generation module, and a simulation-driven fine-tuning module, thus establishing a simulation-driven closed-loop optimization mechanism.
It achieves component-level semantic awareness in the generation of 3D aircraft, precise control of multi-parameter aerodynamic conditions, eliminates systematic deviations between generated geometry and target performance, and improves generation efficiency and aerodynamic performance compliance rate.
Smart Images

Figure CN123069930A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the interdisciplinary technical fields of digital design of aerospace vehicles, three-dimensional generative modeling and computational fluid dynamics, and specifically involves an aerodynamic design method and system based on hierarchical flow matching and simulation-driven fine-tuning. Background Technology
[0002] Aerodynamic design of aircraft and other engineering objects is a core issue in aerospace engineering. Current aircraft aerodynamic shape design typically begins with establishing a parametric geometric model, followed by meshing according to given operating conditions and running physical simulations, such as those based on Computational Fluid Dynamics (CFD) solvers. Designers adjust wingspan, sweep angle, fuselage length, wing area, and relative component positions based on lift, drag, or lift-to-drag ratio, iteratively calculating until constraints are met. While this approach has clear physical implications, a single scheme evaluation often requires remodeling, mesh processing, and numerical solving. As the number of design variables increases, the computational load rises with the number of samples, and the search range is also limited by the initial parametric method. In recent years, deep generative models have been introduced into complex 3D structures (e.g., 3D CAD models, 3D human models, etc.), but existing technologies still have significant limitations in the field of aircraft design.
[0003] (1) High-performance coding method for complex three-dimensional geometry
[0004] Existing patent document CN121725081A discloses a novel three-dimensional spatial voxel encoding representation scheme, which uses 32-bit integers to encode sparse octree node voxels, uses floating bits to represent voxel size, and encodes the coordinates of voxel nodes in three-dimensional space. This scheme is mainly used for voxel encoding and storage in three-dimensional spatial scenes, solving the problems of high memory consumption and slow node positioning and search speed of traditional encoding methods; however, it only involves voxel encoding and storage optimization, and does not involve voxel-based generative modeling, semantic classification of specific equipment parts, or use aerodynamic conditions as generation constraints, so it cannot be directly used for component-level semantic generation and aerodynamic optimization.
[0005] (2) Machine learning-based 3D structure generation
[0006] Existing patent document CN117235929A discloses a generative design method for 3D CAD based on knowledge graphs and machine learning, which obtains a 3D CAD model through product knowledge organization, requirement analysis, and model generation. This method is geared towards general product design and does not involve hierarchical voxel representation of component semantics or incorporate aerodynamic conditions as generation constraints.
[0007] Existing patent document CN120408866A discloses a method for generating 3D parametric models based on artificial intelligence. This method converts natural language requirements into structured data, obtains initial geometry from a deep generative model, and then performs geometric repair, finite element analysis, and manufacturing feasibility verification. Its closed-loop approach focuses on structural and manufacturing constraints, but does not address the generation process of 3D engineering objects based on flow matching, nor does it address how to utilize non-differentiable CFD feedback to update the generated model.
[0008] (3) Conditional flow matching and general 3D generation
[0009] Microsoft Research's TRELLIS and TRELLIS2 document a 3D generation method based on structured latent representation, along with subsequent improvements. These methods unify the representation of various 3D formats, including NeRF, 3D Gaussian, and meshes, and employ a flow matching model for training, supporting text-to-3D and image-to-3D generation. This approach is primarily intended for general 3D asset generation scenarios such as games, simulations, and creative design. However, it lacks constraints on the semantics of engineering objects' components, does not incorporate aerodynamic parameters as generation conditions, and lacks a mechanism for optimization using aerodynamic simulation feedback. Therefore, it cannot directly meet the requirements for aerodynamic shape generation and controllable performance design of engineering objects.
[0010] Existing patent document CN119897865A discloses a robot motion generation method and related apparatus, which uses conditional flow matching for robot motion generation: taking task instructions, body state, and multi-view images as conditions, the next moment's motion pose is output through a parameterized velocity field. This method demonstrates that flow matching can handle conditional generation problems, but the generated object is a sequence of robot motions, not a 3D engineering mesh with component semantics.
[0011] In summary, the existing technology has the following technical problems:
[0012] 1. Existing 3D generation methods lack component-level semantic constraints. The generated results may have a shape, but the boundaries and relative positions of components such as the fuselage, wings, and tail are unstable, making it difficult to directly incorporate them into subsequent aerodynamic evaluations.
[0013] 2. Multiple design conditions are often concatenated into a single condition vector, and the influence of each parameter on the generated result is not easily distinguishable. Given the target wingspan, fuselage length, wing area, angle of attack, and lift-to-drag ratio, existing methods have difficulty controlling the geometric scale and aerodynamic response simultaneously.
[0014] 3. There is a lack of executable feedback update mechanism between the generated model and the physical simulation solver. The physical simulation solver is usually non-differentiable, and the simulation results cannot be directly backpropagated, making it difficult to correct the deviation between the initial generated mesh and the target performance through conventional gradient training.
[0015] 4. Single-stage models need to simultaneously handle overall layout, local surfaces, and aerodynamic performance, with optimization objectives mutually constraining each other. Existing methods do not separate the processing of coarse-grained structure generation, fine-grained geometry generation, global deformation correction, and latent space fine-tuning. Summary of the Invention
[0016] To address the shortcomings of existing technologies, achieve semantic perception of flight components and precise control of aerodynamic conditions, eliminate systematic deviations between the generated geometry and target performance of the aircraft, and improve the efficiency of aircraft generation and the rate of aerodynamic performance compliance, this invention adopts the following technical solution:
[0017] An aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning includes a semantic voxel autoregression generation module, a conditional SLAT flow matching fine geometry generation module, and a simulation-driven fine-tuning module.
[0018] The semantic voxel autoregressive generation module introduces aerodynamic condition parameters into the prediction of the coarse-grained 3D structure of aerodynamic components to obtain voxel occupancy, component semantic labels and global scaling ratio.
[0019] The conditional SLAT flow matching fine geometry generation module encodes multidimensional aerodynamic condition parameters into conditional tokens using independent MLP based on the global scaling ratio to maintain parameter-level interpretability and controllability, and adds positional encoding; it uses voxel occupancy and component semantic labels as structural conditions, and performs conditional flow matching in the structured latent space under the guidance of the conditional token matrix C to generate a fine 3D geometry SLAT latent representation; it decodes the SLAT latent representation and extracts voxel features to generate a triangular mesh;
[0020] The simulation-driven fine-tuning module evaluates the aerodynamic performance of the triangular mesh to provide non-differentiable simulation feedback. Due to its non-differentiable nature, it needs to be optimized using policy gradient or reward weighting methods. A reward value is generated by the error between the aerodynamic performance parameters and the aerodynamic condition parameters. When the reward value reaches a threshold, the final three-dimensional aircraft equipment mesh is output; otherwise, the decoding is adjusted based on global geometric deformation, and the conditional flow matching is adjusted based on the reward value. Fine-tuning is performed in the latent space to make high-aerodynamic performance samples contribute more to flow matching learning.
[0021] Furthermore, in the semantic voxel autoregressive generation module:
[0022] The device is voxelized, and the resulting sparse voxel 3D spatial coordinates are encoded and introduced into component-level semantic tags to generate a sparse octree depthwise to characterize the device’s coarse-grained 3D structure. Hierarchical tokens are constructed by depthwise random masking to preserve the semantics of aircraft components in the generated results. Morton coding is used for 3D spatial Z-order indexing to ensure spatial locality.
[0023] The aerodynamic condition parameters are encoded as conditional latent space features and mutual attention context of a masked autoregressive model;
[0024] The mask autoregressive Transformer model predicts the voxel occupancy signal of the mask position based on the hierarchical lexical tokens, the component semantic tag dictionary, and the global scaling ratio.
[0025] Furthermore, the conditional SLAT stream matching fine geometry generation module includes a conditional tokenization module, a conditional SLAT stream matching generation module, and a FlexiCubes decoder;
[0026] The conditional tokenization module, based on the global scaling ratio, maps each aerodynamic condition parameter into a multidimensional token through an independent two-layer MLP, and adds learnable positional encoding to distinguish different parameters, ultimately obtaining a conditional token matrix.
[0027] The conditional SLAT flow matching generation module, based on the voxel occupancy and component semantic tags, obtains the noise-filled active voxels and the coordinate position encoding of the active voxels. Combined with the conditional token matrix, it performs flow matching using a linear probability path, gradually evolving from Gaussian noise to data distribution, and obtains the denoised SLAT latent representation.
[0028] The FlexiCubes decoder performs topological adaptive surface extraction on the SLAT latent representation to predict sparse voxel features (including SDF values, vertex deformation, FlexiCubes topological weights, and color normals) and fine-tunes them to obtain a triangular mesh.
[0029] Furthermore, the conditional SLAT stream matching generation module starts from Gaussian noise and, guided by the conditional token matrix C, uses a backbone network with a sparse Transformer cross-attention mechanism. It uses SLAT latent features as queries and conditional tokens as keys and values to gradually denoise the data. During training, it adopts logit-normal time scheduling, and during inference, it uses classifier free guidance (CFG) to enhance conditional control, and outputs the denoised SLAT latent representation.
[0030] Furthermore, the classifier is freely guided by the fact that during training, conditions are randomly discarded with probability; during inference, two neural networks are constructed based on conditional and unconditional information and noisy states or intermediate generated states as inputs, and are combined through guiding weights to predict the final velocity field, thereby realizing the conditional and unconditional combination prediction of the classifier freely guided by the fact.
[0031] Furthermore, the simulation-driven fine-tuning module includes a geometric measurement module, a CFD aerodynamic solver, a multi-metric adaptive calibration reward module, a global deformation predictor, and a reward-weighted flow matching module;
[0032] The geometry measurement module acquires the triangular mesh output by the FlexiCubes decoder to calculate the device's geometric parameters;
[0033] The CFD aerodynamic solver calculates aerodynamic parameters based on the simulation conditions.
[0034] The multi-metric adaptive calibration reward module generates a reward value by constructing a reward function, taking into account the differences in physical dimensions and error distribution between the aerodynamic performance parameters (composed of the device's geometric parameters and aerodynamic parameters) and the aerodynamic condition parameters.
[0035] Furthermore, the multi-metric adaptive calibration reward module calculates the error range of each parameter index using the aerodynamic condition parameters of the training set samples. It normalizes the error of each aerodynamic performance parameter and aerodynamic condition parameter by dividing it by the error range. The median of the normalized parameter index error is used as the median error. The Gaussian sharpness parameter is calibrated, and weighted geometric mean aggregation is performed to provide an effective gradient signal. By reasonably adjusting the weight of each parameter index in the overall reward, the weight of the aerodynamic parameter index (angle of attack, lift-to-drag ratio) is increased, and finally, a scalar reward value is output.
[0036] Furthermore, the simulation-driven fine-tuning module also includes a global deformation predictor, which predicts the mean and logarithmic standard deviation of the Gaussian policy distribution of two global deformation parameters, the radial scaling parameter α and the dihedral bending parameter β, using the SLAT latent representation and aerodynamic conditions. These values are then applied to the mesh vertices output by the FlexiCubes decoder. The mean is constrained by the tanh boundary, and the prediction process employs policy gradient learning, which includes EMA baseline, dominance normalization, and amplitude regularization, to eliminate systematic geometric biases.
[0037] Furthermore, the attention layer and feedforward layer of the conditional SLAT flow matching generation module are injected with a low-rank matrix adapter (LoRA).
[0038] The simulation-driven fine-tuning module also includes a reward-weighted flow matching module, which obtains the velocity field predicted by the conditional SLAT flow matching generation module, constructs a joint loss of reward-weighted flow matching loss and Wasserstein distance (W2 distance) regularization and performs joint optimization to make high-reward samples contribute more to velocity field learning, achieve fine aerodynamic property adjustment, and constrains the distance between the adjusted velocity field and the pre-trained reference velocity field to prevent catastrophic forgetting. Finally, the LoRA adapter parameter update is obtained and applied to the SLAT latent representation generation of the conditional SLAT flow matching generation module.
[0039] The aerodynamic design method based on hierarchical flow matching and simulation-driven fine-tuning is used to perform aerodynamic design according to the aforementioned aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning.
[0040] The advantages and beneficial effects of this invention are as follows:
[0041] This invention establishes a hierarchical representation method based on octree sparse voxels, which simultaneously predicts voxel occupancy, component semantic labels (fuselage, wings, other components) and global scaling ratio during the generation process, so that the generated aircraft has a clear component-level semantic structure, thereby realizing component-level semantic awareness in the generation of 3D aircraft.
[0042] This invention designs a conditional flow matching generation model, which encodes multi-dimensional aerodynamic parameters such as wingspan, fuselage length, wing area, angle of attack, and lift-to-drag ratio into independent condition tokens. These tokens are then injected into the generation process through a cross-attention mechanism, achieving a conditional mapping from aerodynamic performance targets to three-dimensional geometry, thereby enabling precise control of multi-parameter aerodynamic conditions.
[0043] This invention designs a two-stage fine-tuning strategy. In the first stage, the strategy gradient is used to learn the global geometric deformation parameters, and in the second stage, reward-weighted flow matching is used to fine-tune them in the latent space. The simulation feedback of the non-differentiable CFD solver is effectively integrated into the optimization of the generative model, eliminating the systematic deviation between the generated geometry and the target performance, and establishing a simulation-driven closed-loop optimization mechanism.
[0044] This invention establishes a phased process of "coarse-grained octree semantic voxel generation - fine-structured latent representation flow matching - global deformation learning - latent space adaptation" by constructing a hierarchical collaborative framework for generation and fine-tuning. This realizes the phased connection from structural layout to fine geometry and from initial generation to simulation optimization, thereby improving generation efficiency and aerodynamic performance compliance rate. Attached Figure Description
[0045] Figure 1 This is a schematic diagram of the system structure in this invention.
[0046] Figure 2This is a flowchart of the method in this invention. Detailed Implementation
[0047] The specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are for illustration and explanation only and are not intended to limit the present invention.
[0048] like Figure 1 As shown, this invention proposes an aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning, applied to 3D aircraft. Using aircraft wingspan, fuselage length, wing area, target global scale conditions, angle of attack, and lift-to-drag ratio as conditions, it sequentially generates coarse-grained component structures and fine-grained 3D meshes. Then, based on geometric measurements and CFD simulation results, it performs two-stage fine-tuning. The system includes an octree semantic voxel autoregressive generation module, a conditional SLAT flow matching fine-grained geometry generation module, and a two-stage simulation-driven fine-tuning module. Figure 1 The dashed lines in the diagram represent parameter updates / fine-tuning feedback, while the solid lines represent data / generation processes.
[0049] The Octree Semantic Voxel Autoregressive Generation Module uses sparse octrees to represent the coarse-grained structure of the aircraft, employs Morton coding for spatial indexing, and generates the coarse-grained 3D structure of the aircraft depthwise through a masked autoregressive Transformer, including voxel occupancy, component semantic labels (fuselage, wings, other components), and global scaling ratio.
[0050] Specifically, the octree semantic voxel autoregressive generation module sparsifies the entire aircraft through the voxel generation module and encodes the 3D spatial coordinates of the sparse voxels into one-dimensional integers using Morton coding, storing them in a hierarchical octree. The coordinates of the sparse voxels and the features on the voxels are encoded into a token sequence. Random masked partial tokens are generated at each depth level. Morton coding is used to perform Z-order indexing in the 3D space to ensure spatial locality. Condition generation is performed through a masked autoregressive Transformer model. The conditions used in condition generation are the encoded aerodynamic condition parameters (wingspan, fuselage length, wing area, angle of attack, lift-to-drag ratio). The encoding process involves encoding the normalized aerodynamic condition parameters into conditional latent space features (embedding) and cross-attention context (cross-attn) through two MLPs. The context), the mask autoregressive Transformer model then predicts the voxel splitting signal, semantic label and global scaling ratio of the mask position based on the voxel token, to obtain a sparse octree representation containing the voxel occupancy signal, semantic label dictionary (fuselage / wing / other), and global scaling ratio, which is used for the initial noise of the activated voxel position and the coordinate position encoding of the activated voxel.
[0051] The Conditional SLAT Flow Matching Fine Geometry Generation Module comprises a Conditional Tokenization Module, a Conditional SLAT Flow Matching Generation Module, and a FlexiCubes Decoder. The Conditional Tokenization Module encodes multidimensional aerodynamic parameters into conditional tokens using independent MLPs to maintain parameter-level interpretability and controllability, and adds positional encoding. The Conditional SLAT Flow Matching Generation Module performs conditional flow matching in the Structured Latent Representation (SLAT) space to generate a fine-grained 3D geometric SLAT latent representation. The FlexiCubes Decoder decodes the SLAT latent representation into a triangular mesh and uses deformation parameters generated by a global deformation predictor for efficient fine-tuning.
[0052] Specifically, the conditional tokenization module obtains six normalized aerodynamic condition parameters, namely wingspan, fuselage length, wing area, target global scale condition s, angle of attack, and lift-to-drag ratio. Normalization is performed by scaling the minimum-maximum values of the dataset to the range of [-1, 1]. Each aerodynamic parameter is mapped to an X-dimensional token through an independent two-layer MLP, and a learnable position code is added to distinguish different parameters, finally resulting in a conditional token matrix (6×X-dimensional).
[0053] The conditional SLAT flow matching generation module acquires noise-filled activation voxels, their coordinate position encodings, and the conditional token matrix. It then performs flow matching using a linear probability path, gradually evolving from Gaussian noise to the data distribution to obtain the denoised SLAT latent representation. A sparse Transformer backbone network employing a cross-attention mechanism uses SLAT latent features as queries and conditional tokens as keys and values. Training utilizes logit-normal time scheduling, while inference employs classifier free guidance (CFG) to enhance conditional control, ultimately generating a high-fidelity 3D mesh.
[0054] The FlexiCubes decoder obtains the SLAT latent representation and uses the FlexiCubes algorithm for topological adaptive surface extraction to predict sparse voxel features (including SDF values, vertex deformation, FlexiCubes topological weights, and color normals). Through a fine-tuning module, it accepts deformation parameters from the global deformation predictor and LoRA updates from reward-weighted flow matching to fine-tune the feature extraction process. During fine-tuning, only the LoRA adapter is updated, and the pre-trained weights are frozen, ultimately yielding a triangular mesh (vertex, face, and vertex color).
[0055] The two-stage simulation-driven fine-tuning module includes a geometry measurement and CFD aerodynamic evaluation module, a multi-metric adaptive calibration reward module, a global deformation predictor, and a reward-weighted flow matching module. The geometry measurement and CFD aerodynamic evaluation module evaluates the aerodynamic performance of the generated mesh and provides non-differentiable simulation feedback. The multi-metric adaptive calibration reward module converts the prediction errors of five design and aerodynamic indices with different dimensions and error distributions into a unified scalar reward signal, providing an effective gradient. The global deformation predictor eliminates the systematic deviation between the generated mesh and the target aerodynamic properties by learning global geometry deformation parameters. The reward-weighted flow matching module performs fine-tuning in the latent space, making high-aerodynamic performance samples contribute more to flow matching learning.
[0056] Specifically, the geometry measurement and CFD aerodynamic evaluation module acquires the triangular mesh output by the FlexiCubes decoder and simulation conditions such as the target angle of attack and incoming flow velocity. Through its geometry measurement module, it calculates the wingspan, fuselage length, and wing area from the mesh vertices. Through its CFD aerodynamic solver, it calculates the lift, drag, and lift-to-drag ratio under a given angle of attack and incoming flow conditions. Finally, it obtains the mesh geometry measurement values and the aerodynamic calculation results under the target conditions. Due to its non-differentiable characteristics, it requires optimization using policy gradient or reward weighting methods.
[0057] The multi-metric adaptive calibration reward module obtains the wingspan, fuselage length, and wing area output by the geometric measurement module, the lift-to-drag ratio under the target angle of attack condition given by the CFD aerodynamic solver, and the corresponding target values for each item. By constructing a multi-metric adaptive calibration reward function, it calculates the error range of each indicator according to the above method, takes into account the differences in physical dimensions and error distribution of the five design and aerodynamic indicators (wingspan, fuselage length, wing area, angle of attack, and lift-to-drag ratio), divides the error of each indicator by the error range to normalize the error of each indicator, and uses the median of each normalized error as the median error. The Gaussian sharpness parameter is calibrated, and then aggregated by weighted geometric mean to provide an effective gradient signal. By reasonably adjusting the weight of each indicator in the overall reward, the weight of aerodynamic indicators (angle of attack, lift-to-drag ratio) is made higher, and finally the scalar reward value R∈(0,1) is output.
[0058] The global deformation predictor employs a lightweight global deformation predictor, undergoing one-stage fine-tuning through global deformation learning. Specifically, it acquires the latent representation of SLAT and aerodynamic conditions, encodes SLAT features and aerodynamic conditions using a four-layer residual MLP, and predicts the mean and logarithmic standard deviation of the Gaussian policy distributions for two global deformation parameters: radial scaling parameter α and concave bending parameter β. These are then applied to the mesh vertices output by the FlexiCubes decoder. The mean is constrained by tanh boundaries, and the prediction process employs policy gradient learning, incorporating EMA baseline, dominance normalization, and amplitude regularization, to eliminate systematic geometric biases.
[0059] The reward-weighted flow matching module undergoes two-stage fine-tuning through latent space adaptation. Specifically, a low-rank matrix adapter (LoRA) is injected into the attention layer and feedforward layer of the conditional SLAT flow matching generation module. By acquiring the velocity field predictions from the conditional SLAT flow matching generation module and the reward signals from the CFD solver, a joint optimization is performed using a reward-weighted flow matching loss and a Wasserstein distance (W2 distance) regularization loss. This maximizes the contribution of high-reward samples to velocity field learning, enabling fine-tuning of aerodynamic properties. The W2 distance regularization constrains the distance between the fine-tuned velocity field and the pre-trained reference velocity field, preventing catastrophic forgetting. Finally, the LoRA adapter parameters are updated and applied to the conditional SLAT flow matching generation module to generate the SLAT latent representation.
[0060] Based on the above system, this invention also proposes an aerodynamic design method based on hierarchical flow matching and simulation-driven fine-tuning, such as... Figure 2 As shown, it includes the following steps:
[0061] Step 1: Input and Preprocessing.
[0062] The system receives five aerodynamic parameters of the aircraft: wingspan b, fuselage length l, wing area A, angle of attack α, and lift-to-drag ratio ρ. Each aerodynamic parameter is then normalized to the interval [-1, 1] based on the minimum and maximum values of the dataset.
[0063] Step 2: Coarse-grained structure generation.
[0064] The octree autoregressive generation module receives normalized aerodynamic conditions and generates sparse octree representations depth by depth. Morton coding is used for spatial indexing, and masked autoregressive Transformer predicts voxel occupancy, semantic labels (fuselage / wing / others), and global scaling ratio. The final output is a sparse octree structure with a resolution of up to X³.
[0065] Specifically, component-level semantic tags are introduced in the octree generation process to preserve the semantics of aircraft components in the generated results. This includes the following steps:
[0066] Step 2.1: Morton coding space index.
[0067] For a voxel of depth d, its three-dimensional coordinates (x, y, z) are converted into a one-dimensional index through Morton coding. This coding ensures spatial locality, and the Morton codes of adjacent voxels are close, which makes it easier for the Transformer to capture local structures.
[0068] Step 2.2: Use a masked autoregressive Transformer to simultaneously predict three types of signals for each masked token: split signal, semantic label, and global scaling ratio.
[0069] Splitting signal s∈{0,1}: Whether the voxel is subdivided into 8 sub-voxels;
[0070] Semantic label l∈{0,1,2}: 0 represents the wing, 1 represents the fuselage, and 2 represents other components;
[0071] Global scaling ratio σ∈[0,1]: Predicts all voxel features by aggregating them through the global token.
[0072] The joint training loss is:
[0073]
[0074] in, This represents the cross-entropy loss of the split signal. Represents the semantic label cross-entropy loss. This represents the global scaling ratio mean squared error loss. The weight coefficients represent the cross-entropy loss of semantic labels. This represents the weighting coefficient for the global scaling ratio mean squared error loss.
[0075] Step 3: Conditional coding.
[0076] The conditional tokenization module maps the six normalized parameters to X-dimensional tokens through independent MLPs and adds learnable positional encodings to form a 6×X-dimensional conditional token matrix C.
[0077] Specifically, a conditional tokenization scheme with independent parameter-level coding is designed to ensure interpretable control of multidimensional aerodynamic parameters.
[0078] Independent MLP encoding: Each aerodynamic parameter is mapped to a token through two independent MLP layers, as shown in the following formula:
[0079]
[0080] in, Representing normalized parameters, independent coding makes the impact of each parameter traceable, facilitating subsequent analysis and debugging. This represents the k-th parameter, token, after mapping. Indicates a mapping operation. This indicates that dimension X is a real number.
[0081] Positional coding differentiation: Add learnable positional coding The final conditional token matrix C is:
[0082] C = E + P
[0083] in, The token parameter represents the stack.
[0084] Step 4: Refined geometry generation.
[0085] The conditional SLAT flow matching module starts with Gaussian noise and gradually denoises it through a sparse Transformer cross-attention mechanism under the guidance of the conditional token matrix C. The conditional control is enhanced by classifier-free guidance (CFG). Finally, the denoised SLAT latent representation is output.
[0086] Specifically, cross-attention injection is a mechanism in sparse Transformers where SLAT latent features are used as query Q, and the conditional token matrix C is used as key K and value V. This cross-attention mechanism makes the generation process conditionally guided at each Transformer layer.
[0087] Classifier free guidance refers to the process of training with probability... Discard conditions randomly; during inference, combine conditional and unconditional predictions according to the following formula:
[0088]
[0089] in, This represents the noisy state or intermediate generated state at time t. Indicates the diffusion time step. This represents the final velocity field predicted by the model after the classifier has been freely guided and corrected. Indicates guidance strength, used to enhance conditional control. The parameter is The neural network represents the neural network used to parameterize the velocity field in the flow matching model. Represents the conditional information of the model. This indicates an empty condition, meaning the model performs unconditional predictions.
[0090] Step 5: Mesh decoding.
[0091] The FlexiCubes decoder (including the LoRA adapter) extracts the surface using the FlexiCubes algorithm and predicts sparse voxel features (SDF, vertex deformation, topological weight, color normal) to decode the latent representation into a triangular mesh.
[0092] Step 6: Aerodynamic performance evaluation.
[0093] The geometry measurement module calculates wingspan, fuselage length, and wing area from the generated mesh; the CFD aerodynamic solver calculates lift, drag, and lift-to-drag ratio under target angle of attack and flight conditions, and combines the three geometric errors, angle of attack condition consistency, and lift-to-drag ratio error into a scalar reward R through a reward function.
[0094] Specifically, this invention addresses the gradient vanishing problem caused by a single sharpness parameter by constructing a multi-metric adaptive calibration reward function for a heterogeneous design of five design and aerodynamic parameters.
[0095] Relative error normalization: The error of each metric k divided by the dataset range. Obtain the relative error The purpose is to eliminate differences in dimensions and make different indicators comparable.
[0096] Adaptive sharpness calibration: median error Mapped to component rewards X∈(0,1), this calibration guarantees that each metric has a non-zero gradient within its typical error range.
[0097]
[0098] Weighted geometric mean aggregation:
[0099]
[0100] in, Indicates the components of each indicator. Represents an exponential function. This represents the gradient coefficient of index k. This represents the weight of each predefined indicator, expressed as a non-negative real number. A larger value indicates a greater impact of that indicator on the total reward. The geometric mean ensures that excessive error in any indicator will significantly reduce the total reward, avoiding the masking effect of the arithmetic mean. Aerodynamic indicators (angle of attack, lift-to-drag ratio) have higher weights, reflecting their importance in the design.
[0101] Step 7: Fine-tune judgment and execution.
[0102] If the reward R does not reach the preset threshold or is in the training phase, the fine-tuning process begins. After fine-tuning, the process returns to step 4 to regenerate the refined geometry until the performance requirements are met. Fine-tuning includes two stages:
[0103] Fine-tuning stage one: The global deformation predictor outputs a Gaussian policy distribution of radial scaling α and upper anti-angle bending β, samples deformation parameters and applies them to mesh vertices, and updates predictor parameters using policy gradients;
[0104] Fine-tuning Phase 2: The reward-weighted flow matching module uses the reward R-weighted flow matching loss, combined with W2 distance regularization, to update the LoRA adapter of the SLAT flow model.
[0105] Specifically, this invention designs a phased fine-tuning strategy for global geometric deviations and local aerodynamic properties, effectively utilizing the feedback from the non-differentiable CFD solver.
[0106] In the global deformation learning of the global deformation predictor in the fine-tuning stage one, a lightweight global deformation predictor is designed to learn only two global parameters:
[0107] Radial scaling α: controls the overall scale; the radial deformation formula is:
[0108]
[0109] in, Represents normalized voxel coordinates. Voxel representation The center of mass;
[0110] Dihedral bending β: controls the dihedral angle of the wing; the dihedral deformation formula is:
[0111]
[0112] in, Indicates the spanwise component;
[0113] The total transformation is It applies to all mesh vertices.
[0114] The predictor outputs a Gaussian policy distribution:
[0115]
[0116] in, This indicates that the distribution follows a normal distribution. This represents the mean of the radial scaling α. This represents the variance of the radial scaling α. This represents the mean value of the upward concave angle bend β. This represents the variance of the upward concave curvature β.
[0117] The policy gradient loss is:
[0118]
[0119] in, This indicates the advantage of normalization. Indicates amplitude regularity, This represents the weighting coefficient for amplitude regularization. This indicates the number of samples in a batch. Represents the learnable parameters of the policy network. This represents the initial grid for the i-th sample. This represents the conditional information for the i-th sample.
[0120] During the latent space adaptation process of the reward-weighted flow matching module in fine-tuning phase one, a LoRA adapter is injected into the SLAT flow model, and the rank... Scaling The reward-weighted flow matching loss is:
[0121]
[0122] The first term is the reward-weighted flow matching loss, and the second term is the W2 distance regularization. Specifically, Indicates the expectation. This represents the reward calculated from the currently generated sample. This represents the velocity field prediction model after LoRA injection and fine-tuning. Indicates conditional information, This represents the target velocity field corresponding to the probability path. This represents the original samples in the training data. This represents the weight of the regularization term in the reference model, used to balance reward optimization with preserving the capabilities of the original model. This represents the velocity field predicted by the frozen pre-trained SLAT reference model. This design allows high-reward samples to contribute more to the learning of the velocity field, while constraining the fine-tuned model to not deviate from the pre-training distribution.
[0123] Two-stage synergy: Stage 1 corrects global geometric deviations (overall dimensions, wing dihedral), and Stage 2 adjusts local aerodynamic properties in the latent space (lift-to-drag ratio, angle-of-attack response). The two stages can be trained sequentially or applied independently.
[0124] Step 8: Output.
[0125] Output a triangular mesh that meets the aerodynamic performance target, including vertex coordinates, face indices, and vertex colors.
[0126] Taking a certain aircraft design task as an example, the target aerodynamic parameters are: wingspan of 40 meters, fuselage length of 170 meters, wing area of 700 square meters, angle of attack of 15 degrees, and lift-to-drag ratio of 20. Dataset construction: Based on the OpenVSP parametric model, 110 basic aircraft configurations were manually designed. For each configuration, parameters such as wing sweep angle, wing scaling, fuselage length, relative component positions, and overall scaling were systematically perturbed, generating approximately 1024 variants, totaling approximately 110,000 aircraft configurations. The aerodynamic performance of each configuration was evaluated using a self-developed aerodynamic solver. The specific execution process is as follows:
[0127] 1. Input and preprocessing: Input the target aerodynamic parameters and statistically normalize them to the interval [-1, 1] according to the dataset.
[0128] 2. Coarse-grained generation: The octree autoregressive generation module generates a sparse octree of depth 6 (64³ resolution), including voxel occupancy, semantic labels (fuselage / wing / other), and global scaling. Generation time is approximately 2 seconds.
[0129] 3. Refined Geometry Generation: Octree voxels are converted into structured noise in space. The conditional tokenization module encodes six aerodynamic parameters into a 6×768-dimensional conditional matrix. The conditional SLAT flow matching module performs multi-step denoising under CFG guidance to generate a refined latent representation. The FlexiCubes decoder outputs a triangular mesh. Generation time is approximately 10 seconds.
[0130] 4. Aerodynamic Assessment: The geometry measurement module calculates the wingspan, fuselage length, and wing area, while the CFD solver calculates the lift-to-drag ratio under the target angle of attack condition. The initial generated wingspan error is approximately 2.3%, fuselage length error is approximately 2.2%, wing area error is approximately 7.3%, angle of attack error is approximately 37.5%, and lift-to-drag ratio error is approximately 47.4%.
[0131] 5. Fine-tuning Stage 1: The global deformation predictor outputs deformation parameters with radial scaling α = 0.05 and dihedral bending β = -0.02, which are applied to the mesh vertices. After fine-tuning, the wingspan error is reduced to 1.7%, the fuselage length error to 1.5%, and the wing area error to 3.9%.
[0132] 6. Fine-tuning Phase Two: The reward-weighted flow matching module updates the LoRA adapter of the SLAT flow model. After fine-tuning, the angle-of-attack error is reduced to 16.8%, and the lift-to-drag ratio error is reduced to 25.5%.
[0133] 7. Output: The final generated aircraft mesh meets all size and aerodynamic performance objectives.
[0134] The execution result is as follows:
[0135] Generation efficiency: The total time from aerodynamic parameters to a three-dimensional mesh that meets performance requirements is less than 1 minute, which is at least tens of times more efficient than traditional iterative optimization methods (which take several hours to several days).
[0136] Aerodynamic performance compliance rate: The average error of the five indicators is less than 10%, meeting the engineering design requirements. Compared with the initial generation without fine-tuning, the performance is improved after fine-tuning.
[0137] Component semantic accuracy: The generated aircraft component labels are accurate, and the boundaries of components such as fuselage, wings, and tail are clear, with a significant improvement in spatial IoU compared to general methods.
[0138] Generalization ability: On the test set described in the original material, the quality of the generated unseen combinations of conditions is close to that of the training set; however, this conclusion should still be based on the complete test record.
[0139] The above embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.
Claims
1. An aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning, comprising a semantic voxel autoregressive generation module, a conditional flow matching fine geometry generation module, and a simulation-driven fine-tuning module, characterized in that: The semantic voxel autoregressive generation module introduces aerodynamic condition parameters into the prediction of the coarse-grained 3D structure of aerodynamic components to obtain voxel occupancy, component semantic labels and global scaling ratio. The conditional flow matching fine geometry generation module encodes aerodynamic conditional parameters into conditional terms and adds positional encoding based on the global scaling ratio; Using the voxel occupancy and component semantic tags as structural conditions, conditional flow matching is performed in the structured latent space under the guidance of conditional lexical units to generate a latent representation of fine three-dimensional geometry. The latent representation is decoded and voxel features are extracted to generate a mesh; The simulation-driven fine-tuning module evaluates the aerodynamic performance of the mesh, generates a reward value based on the error between the aerodynamic performance parameters and the aerodynamic condition parameters, outputs the final device mesh when the reward value reaches a threshold, otherwise adjusts the decoding based on global geometric deformation, and adjusts the conditional flow matching based on the reward value.
2. The aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning according to claim 1, characterized in that: In the semantic voxel autoregression generation module; The device is voxelized, the resulting sparse voxel 3D spatial coordinates are encoded and introduced into component-level semantic tags to generate a sparse octree depthwise, and hierarchical lexical units are constructed through depthwise random masking. The aerodynamic condition parameters are encoded as conditional latent space features and mutual attention context of a masked autoregressive model; The mask autoregressive model is based on the voxel occupancy signal of the mask position predicted by the hierarchical lexical, the component semantic tag dictionary, and the global scaling ratio.
3. The aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning according to claim 1, characterized in that: The conditional flow matching fine geometry generation module includes a conditional lexicalization module, a conditional flow matching generation module, and a decoder; The conditional lexicalization module, based on the global scaling ratio, maps each aerodynamic condition parameter to a multidimensional lexical and adds learnable positional encoding to distinguish different parameters, ultimately obtaining a conditional lexical matrix. The conditional flow matching generation module, based on the voxel occupancy and component semantic tags, obtains the noise-filled active voxels and the coordinate position encoding of the active voxels, and combines them with the conditional lexical matrix to perform flow matching, gradually evolving from Gaussian noise to data distribution, and obtaining the denoised potential representation. The decoder performs topological adaptive surface extraction on the latent representation to predict sparse voxel features and obtain a mesh.
4. The aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning according to claim 3, characterized in that: The conditional flow matching generation module starts from Gaussian noise, guided by the conditional term matrix, and uses a backbone network with a sparse cross-attention mechanism. It uses latent features as queries and conditional terms as keys and values to gradually denoise the data. It then uses a classifier to freely guide and enhance conditional control, and outputs the denoised latent representation.
5. The aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning according to claim 4, characterized in that: The classifier is freely guided by probability. During training, conditions are randomly discarded with probability. During inference, two neural networks are constructed based on conditional and unconditional information and noisy states or intermediate generated states as inputs. These neural networks are then combined through guiding weights to predict the final velocity field, thus achieving a combination of conditional and unconditional prediction by the classifier.
6. The aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning according to claim 3, characterized in that: The simulation-driven fine-tuning module includes a geometric measurement module, an aerodynamic solver, a multi-metric adaptive calibration reward module, a global deformation predictor, and a reward-weighted flow matching module. The geometric measurement module acquires the grid output by the decoder to calculate the device's geometric parameters; The aerodynamic solver calculates aerodynamic parameters based on the simulated operating conditions. The multi-metric adaptive calibration reward module generates a reward value by constructing a reward function, taking into account the differences in physical dimensions and error distribution between the aerodynamic performance parameters (composed of the device's geometric parameters and aerodynamic parameters) and the aerodynamic condition parameters.
7. The aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning according to claim 6, characterized in that: The multi-metric adaptive calibration reward module calculates the error range of each parameter index based on the aerodynamic condition parameters of the training set samples. It normalizes the error of each aerodynamic performance parameter and aerodynamic condition parameter by dividing it by the error range. The median of the normalized parameter index error is used as the median error, and a weighted geometric mean aggregation is performed. By adjusting the weight of each parameter index in the overall reward, the aerodynamic parameters are given a high weight, and the reward value is finally output.
8. The aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning according to claim 6, characterized in that: The simulation-driven fine-tuning module also includes a global deformation predictor, which predicts the mean and logarithmic standard deviation of the Gaussian policy distribution of the radial scaling parameter and the dihedral bending parameter through the latent representation and aerodynamic conditions, and applies them to the mesh vertices output by the decoder.
9. The aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning according to claim 6, characterized in that: The attention layer and feedforward layer of the conditional flow matching generation module are injected with a low-rank matrix adapter. The simulation-driven fine-tuning module also includes a reward-weighted flow matching module, which obtains the velocity field predicted by the conditional flow matching generation module, constructs a joint loss of reward-weighted flow matching loss and distance regularization and performs joint optimization so that high reward samples contribute more to velocity field learning, and adjusts the distance between the velocity field after distance regularization constraint and the pre-trained reference velocity field, and finally obtains the updated adapter parameters, which are applied to the latent representation generation of the conditional flow matching generation module.
10. An aerodynamic design method based on hierarchical flow matching and simulation-driven fine-tuning, characterized in that: Aerodynamic design is performed using the aerodynamic design system based on hierarchical flow matching and simulation-driven fine-tuning as described in any one of claims 1 to 9.
Citation Information
Patent Citations
Three-dimensional CAD (computer-aided design) generative design method based on knowledge graph and machine learning
CN117235929A
Robot action generation method and related device
CN119897865A
Method and device for generating three-dimensional parameterized model based on artificial intelligence
CN120408866A
Novel coding representation scheme of three-dimensional space voxels
CN121725081A
