Transolver: A Fast Transformer Solver for PDEs on General Geometries
相关信息
论文地址:Transolver: A Fast Transformer Solver for PDEs on General Geometries
代码(Pytorch版):https://github.com/thuml/transolver
Abstract
Since PDEs are typically discretized into large-scale meshes with complex geometries, it's hard for traditional Transformers to capture intricate physical corrlations directly form massive individual points.
So the team present Transolver(Physics Attention)
learning intrinsic physical states hidden behind discretized geometries.Physics Attention
adaptively split the discretized domain into a set of slides with flexible shapes.by calculatiing attention to physics-aware tokens encoded from slices, Transolver
can effectivly capture the physical correlations under complex geometries and compute in linear complexity.
Method
Problem Defination:
Input domain \(\Omega \subset \mathbb{R}^{C_g}\), where \(C_g\) denotes the dim of input space.\(\Omega\) is discretized into a set of meshes points \(\mathbb{g} \subset \mathbb{R}^{C_g \times N}\).The task is to estimate target physical quantities based on input geometrics \(\mathbb{g}\) and quantities \(\mathbb{u} \in \mathbb{R}^{N \times C_u}\).
Here \(\mathbb{u}\) is optional in some PDE-governed problems.
The key to solving PDEs is to capture intricate physical correlations.But it's hard for Attention
to learn from such massive discretized mesh points.
These mesh points are a finite discrete sampling(有限离散采样) of the underlying continuous physics space,which inspires us to capture the intrinsic physical states hidden behind discretized geometries.
We find that the surface mesh set can be ascribed to several physically internal-consistent subsets(物理上内部一致的子集),such as front, bevel, back areas.
Given a mesh set \(\mathbb{g}=\{\mathbb{g}_i\}^N_{i=1}\) with the coordinates information(坐标信息) of \(N\) mesh points and observed quantities \(\mathbb{u}\), we embed them into deep features \(\mathbb{x}=\{\mathbb{x}_i \in \mathbb{R}^{1 \times C} \}^N_{i=1}\) by a linear layer, where \(x_i\) involves both geometry and physics information.
We ascribes each mesh point \(g_i\) to \(M\) potential slices based on its learned feature \(X_i\):
\(\sum^M_{j=1} w_{i,j}=1\).Specifically, \(w_{i,j}\) represents the degree that the i-th point belongs to the j-th slices.
\(s_j\) represents the j-th slice feature, which is a weighted sum of all mesh points' features \(x\).
mesh points with close features will derive similar slice weights, which means they are more likely to be assigned to the same slice.
Since each slice contains mesh points with similar geometry and physics features, we encode them into physical-aware tokens \(z_j\).
Why does this silce method work? :
In the method, slice weights are projected from mesh features, which means that mesh points with similar features will get similar slice weights(will be assigned to the same slice). it is useful to capture points under similar physical states but spatially distant.
Physics-Attention
We employ attention mechanism to capture intricate correlations among diffenert physical states:
Then \(z'={z'_j}^M_{j=1}\) are transformed back to mesh points:
where \(1 ≤ i ≤ N\) and each token is broadcasted to all mesh points.
The whole process can be summarized as:
where \(l \in \{ 1,...,L \}\), \(\mathbf{x}^l \in \mathbb{R}^{N \times C}\) is the l-th layer output.\(\mathbf{x}^0 \in \mathbb{R}^{N \times C}\) represents the input deep feature, which is embedde from input geometries \(g \in \mathbb{g}^{N \times C_g}\) and observed quantities \(\mathbb{u} \in \mathbb{R}^{N \times C_u}\). by linear layer.
Toward an intuitive understanding of Transolver, we visualize Physics-Attention.In the inner-stress estimation task of Elasticity,we can observe that slices learn to cover diverse subareas that are under similar extrusion degress, such as the left and right of the hollow area, corners of the material.
Which suprising us is that for 50% randomly sampled input mesh of Elasticity, Transolver can still capture physical states precisely even for broken meshes.
Out-of-distribution(OOD) generalization:
In the previous research, neural solvers are mainly trained and tested with samples under the same or in-distribution PDE coefficients and varied initial or boundary conditions.
For example, in the car design task, different samples of diverse shapes are all generated under the headwind(逆风) with the same speed. As for the airfoil design, although training samples contain various Reynolds and angles of attacks, the test set is still under the same range of Reynolds and angles as the training set.
To further examine the generalizability(泛化性) of Transolver in real-world applications, we experiment with OOD airfoil design tasks, where the test set has completely different Reynolds and angles of attacks.
Benchmark
(1)Elasticity
(2)Plasticity
(3)Airfoil
(4)Pipe
(5)NS
(6)Darcy
(7)Shape-Net Car
(8)AirfRANS
Code
models
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 |
|