SwitchNet: a neural network model for forward and inverse scattering problems

Yuehaw Khoo, Lexing Ying

Introduction

In this paper, we study the forward and inverse scattering problems via the use of artificial neural networks (NNs). In order to simplify the discussion, we focus on the time-harmonic acoustic scattering in two dimensional space. The inhomogeneous media scattering problem with a fixed frequency ω\omega is modeled by the Helmholtz operator

where c(x)c(x) is the velocity field. In many settings, there exists a known background velocity field c0(x)c_{0}(x) such that c(x)c(x) is identical to c0(x)c_{0}(x) except in a compact domain Ω\Omega. By introducing the scatterer η(x)\eta(x) compactly supported in Ω\Omega

we can equivalently work with η(x)\eta(x) instead of c(x)c(x). Note that in this definition η(x)\eta(x) scales quadratically with the frequency ω\omega. However, as ω\omega is assumed to be fixed throughout this paper, this scaling does not affect any discussion below.

In many real-world applications, η(⋅)\eta(\cdot) is unknown. The task of the inverse problem is to recover η(⋅)\eta(\cdot) based on some observation data d(⋅)d(\cdot). The observation data d(⋅)d(\cdot) is often a quantity derived from the Green’s function G=L−1G=L^{-1} of the Helmholtz operator LL and, therefore, it depends closely on η(⋅)\eta(\cdot). This paper is an exploratory attempt of constructing efficient approximations to the forward map η→d\eta\rightarrow d and the inverse map d→ηd\rightarrow\eta using the modern tools from machine learning and artificial intelligence. Such approximations are highly useful for the numerical solutions of the scattering problems: an efficient map η→d\eta\rightarrow d provides an alternative to expensive partial differential equation (PDE) solvers for the Helmholtz equation; an efficient map d→ηd\rightarrow\eta is more valuable as it allows us to solve the inverse problem of determining the scatterers from the scattering field, without going through the usual iterative process.

In the last several years, deep neural network has become the go-to method in computer vision, image processing, speech recognition and many other machine learning applications . More recently, methods based on NN have also been applied to solving PDEs. Based on the way that the NN is used, these methods for solving the PDE can be roughly separated into two different categories. For the methods in the first category , instead of specifying the solution space via the choice of basis (as in finite element method or Fourier spectral method), NN is used for representing the solution. Then an optimization problem, for example an variational formulation, is solved in order to obtain the parameters of the NN and hence the solution to the PDE. Similar to the use of an NN for regression and classification purposes, the methods in the second category such as use an NN to learn a map that goes from the coefficients in the PDE to the solution of the PDE. As in machine learning, the architecture design of an NN for solving PDE usually requires the incorporation of the knowledge from the PDE domain such that the NN architecture is able to capture the behavior of the solution process. Despite the abundance of the works in using the NN for solving PDE, none of the above mentioned methods have tried to obtain the solution to the wave equation.

This paper takes a deep learning approach to learn both the forward and inverse maps. For the Helmholtz operator (1), we propose an NN architecture for determining the forward and inverse maps between the scatterer η(⋅)\eta(\cdot) and the observation data d(⋅)d(\cdot) generated from the scatterer. Although this task looks similar to the computer vision problems such as image segmentation, denoising, and super-resolution where the map between the two images has to be determined, the nature of the map in our problem is much more complicated. In many image processing tasks, the value of a pixel at the output generally only depends on a neighborhood of that pixel at the input layer. However, for the scattering problems, the input and output are often defined on different domains and, due to wave propagation, each location of the scatterer can influence every point of the scattered field. Therefore, the connectivity in the NN has to be wired in a non-local fashion, rendering typical NN with local connectivity insufficient. This leads to the development of the proposed SwitchNet. The key idea is the inclusion of a novel low-complexity switch layer that sends information between all pairs of sites effectively, following the ideas from butterfly factorizations . The same factorization was used earlier in the architecture proposed , but the network weights there are hardcoded and not trainable.

The paper is organized as followed. In Section 2, we discuss about some preliminary results concerning Helmholtz equation. In Section 3, we study the so called far field pattern of the scattering problem, where the sources and receivers can be regarded as placed at infinity. We propose SwitchNet to determine the maps between the far field scattering pattern and the scatterer. In Section 4, we turn to the setting of a seismic imaging problem. In this problem, the sources and receivers are at a finite distance, but yet well-separated from the scatterer.

Preliminary

Using the background velocity field c0(x)c_{0}(x), we first introduce the background Helmholtz operator L0=−Δ−ω2/c02L_{0}=-\Delta-\omega^{2}/c_{0}^{2}. With the help of L0L_{0}, one can write LL in a perturbative way as

where EE is viewed as a perturbation. By introducing the background Green’s function

one can write down a formal expansion for the Green’s function G=L−1G=L^{-1} of the η\eta-dependent Helmholtz operator LL:

which is valid when the scatterer field η(x)\eta(x) is sufficiently small. The last line of the above equation serves as the definition of the successive terms of the expansion (G1G_{1}, G2G_{2}, and so on). As G0G_{0} can be computed from the knowledge of the background velocity field c0(x)c_{0}(x), most data gathering processes (with appropriate post-processing) focus on the difference G−G0=G1+G2+⋯G-G_{0}=G_{1}+G_{2}+\cdots instead of GG itself.

A usual experimental setup consists of a set of sources SS and a set of receivers RR:

The data gathering process usually involves three steps: (1) impose an external force or incoming wave field via some sources, (2) solve for the scattering field either computationally or physically, (3) gather the data with receivers at specific locations or directions. The second step is modeled by the difference of the Green’s function G−G0G-G_{0}, as we mentioned above. As for the other steps, it is convenient at this point to model the first step with a source-dependent operator ΠS\Pi_{S} and the third one with a receiver-dependent operator ΠR\Pi_{R}. We shall see later how these operators are defined in more concrete settings. By putting these components together, one can set the observation data dd abstractly as

In this paper, we focus on two scenarios: far field pattern and seismic imaging. We start with far field pattern first to motivate and introduce SwitchNet. We then move on to the seismic case by focusing on the main differences.

SwitchNet for far field pattern

In this section, we consider the problem of determining the map from the scatterer to the far field scattering pattern, along with its inverse map. Without loss of generality, we assume that the diameter of the domain Ω\Omega is of O(1)O(1) after appropriate rescaling. The background velocity c0(x)c_{0}(x) is assumed to be 1 since the far field pattern experiments are mostly performed in free space.

In this limiting setting, one redefine the observation data as

Now taking the two limits (10) and (14) under consideration, one arrives at the following representation of the observation data d(r,s)d(r,s) for r∈Rr\in R and s∈Ss\in S

2. Low-rank property

The intuition behind the proposed NN architecture comes from examining (19) when EE (or η\eta) is small. In such a situation, we simply retain the term that is linear in EE. Using the fact that E=diag(η)E=\text{diag}(\eta), (19) becomes

For any DiD_{i} and XjX_{j}, the submatrix

The proof of this theorem follows the same line of argument in and below we outline the key idea. Denote the center of DiD_{i} by (ri,si)(r_{i},s_{i}) and the center of XjX_{j} by xjx_{j}. For each (r,s)∈Di(r,s)\in D_{i} and x∈Xjx\in X_{j}, we write

Note that for fixed DiD_{i} and XjX_{j} each of the last three terms is either a constant or depends only on xx or (r,s)(r,s). As a result, exp⁡(iω(s−r)⋅x)\exp(i\omega(s-r)\cdot x) is numerically low-rank if and only if the first term exp⁡(iω((s−r)−(si−ri))⋅(x−xj))\exp(i\omega((s-r)-(s_{i}-r_{i}))\cdot(x-x_{j})) is so. Such a low-rank property can be derived from the conditions concerning the side-lengths of DiD_{i} and XjX_{j}. More precisely, since (r,s)(r,s) resides in DiD_{i} with center (ri,si)(r_{i},s_{i}), then

Similarly as xx resides in XjX_{j} with center xjx_{j}, then

Multiplying these two estimates results in the estimate

for the phase of exp⁡(iω((s−r)−(si−ri))⋅(x−xj))\exp(i\omega((s-r)-(s_{i}-r_{i}))\cdot(x-x_{j})). Therefore,

for (r,s)∈Di(r,s)\in D_{i} or x∈Xjx\in X_{j} is non-oscillatory and hence can be approximated effectively by applying, for example, Chebyshev interpolation in both the (r,s)(r,s) and xx variables. Since the degree of the Chebyshev polynomials only increases poly-logarithmically with respect to the desired accuracy, exp⁡(iω((s−r)−(si−ri))⋅(x−xj))\exp(i\omega((s-r)-(s_{i}-r_{i}))\cdot(x-x_{j})) is numerically low-rank by construction. This proves that the submatrix AijA_{ij} defined in (22) is also numerically low-rank. ∎

3. Matrix factorization

By applying (28) to each block AijA_{ij}, AA can be approximated by

The next step is to write (29) into a factorized form. First, introduce UiU_{i} and VjV_{j}

With the above definitions for UU, VV, and Σ\Sigma, the approximation in (29) can be written compactly as

Notice that although AA has M2×N2M^{2}\times N^{2} entries, using the factorization (34), AA can be stored using tP(M2+P+N2)tP(M^{2}+P+N^{2}) entries. In this paper, P≈max⁡(M,N)P\approx\max(M,N) and MM and NN are typically on the same order. Therefore, instead of O(N4)O(N^{4}), one only needs O(N3)O(N^{3}) entries to parameterize the map AA approximately using (34). Such a factorization is also used in for the compression of Fourier integral operators.

We would like to comment on another property that may lead to further reduction in the parameters used for approximating AA. Let us focus on any two submatrices AijA_{ij} and AikA_{ik} of AA. For two regions XjX_{j} and XkX_{k}, where the center of XjX_{j} and XkX_{k} are xjx_{j} and xkx_{k} respectively, Xk=Xj+(xk−xj)X_{k}=X_{j}+(x_{k}-x_{j}). Let (r,s)∈Di(r,s)\in D_{i}. For x∈Xjx\in X_{j} and x′=x+(xk−xj)∈Xkx^{\prime}=x+(x_{k}-x_{j})\in X_{k}, we have

Therefore, the low-rank factorizations of AijA_{ij} and AikA_{ik} are solely determined by the factorization of h(rs,x)h(rs,x). This implies that it is possible to construct low-rank factorizations for AijA_{ij} and AikA_{ik}:

such that Vij∗=Vik∗V^{*}_{ij}=V^{*}_{ik}. Since this is true for all possible j,kj,k, one can pick low-rank factorizations so that V0=V1=⋯=VP−1V_{0}=V_{1}=\cdots=V_{P-1}.

As a final remark in this section, this low complexity factorization (34) for AA can be easily converted to one for A∗A^{*} since

where U,Σ,VU,\Sigma,V are provided in (30), (31), and (32).

4. Neural networks

Based on the low-rank property of AA in Section 3.2 and its low-complexity factorization in Section 3.3, we propose new NN architectures for representing the inverse map d→ηd\rightarrow\eta and the forward map η→d\eta\rightarrow d.

As pointed out earlier, d≈Aηd\approx A\eta when η\eta is sufficiently small. The usual filtered back-projection algorithm solves the inverse problem d→ηd\rightarrow\eta via

where ϵ\epsilon is the regularization parameter. In the far field pattern problem, (A∗A+ϵI)−1(A^{*}A+\epsilon I)^{-1} can be understood as a deconvolution operator. To see this, a direct calculation reveals that

for x,y∈Xx,y\in X. (41) shows that A∗AA^{*}A is a translation-invariant convolution operator. Therefore, the operator (A∗A+ϵI)−1(A^{*}A+\epsilon I)^{-1}, as a regularized inverse of A∗AA^{*}A, simply performs a deconvolution. In summary, the above discussion shows that in order to obtain η\eta from the scattering pattern dd in the regime of small η\eta, one simply needs to apply sequentially to dd

a translation-invariant filter that performs the deconvolution (A∗A+ϵI)−1(A^{*}A+\epsilon I)^{-1}.

Although these two steps might be sufficient when η\eta is small, a nonlinear solution is needed when η\eta is not so. For this purpose, we propose a nonlinear neural network SwitchNet for the inverse map. There are two key ingredients in the design of SwitchNet.

The first key step is the inclusion of a Switch layer that sends local information globally, as depicted in Figure 4. The structure of the Switch layer is designed to mimic the matrix-vector multiplication of the operator A∗≈VΣ∗U∗A^{*}\approx V\Sigma^{*}U^{*} in (29). However unlike the fixed coefficients in (29), as an NN layer, the Switch layer allows for tunable coefficients and learns the right values for the coefficients from the training data. This gives the architecture a great deal of flexibility.

The second key step is to replace the linear deconvolution in the back-projection algorithm with a few convolution (Conv) layers. This enriches the architecture with nonlinear capabilities when approximating the nonlinear inverse map.

These basic building blocks of SwitchNet are detailed in the following subsection. We also take the opportunity to include the details of the pointwise multiplication PM layer that will be used in later on.

4.2. Layers for SwitchNet

In this section we provide the details for the layers that are used in SwitchNet. Henceforth, we assume that the entries of a tensor is enumerated in the Python convention, i.e., going through the dimensions from the last one to the first. One operation that will be used often is a reshape, in which a tensor is changed to a different shape with the same number of entries and with the enumeration order of the entries kept unchanged.

Swap the second and the third dimensions to get a P×P×nP×nP{\sqrt{P}}\times{\sqrt{P}}\times\frac{n}{\sqrt{P}}\times\frac{n}{\sqrt{P}} tensor.

Swap the second and the third dimensions to get a P×nP×P×nP{\sqrt{P}}\times\frac{n}{\sqrt{P}}\times{\sqrt{P}}\times\frac{n}{\sqrt{P}} tensor.

Here the non-zero entries of U,VU,V are the trainable parameters. The Switch layer is illustrated in Figure 4.

We remark that, among these layers, the Switch layer has the most parameters. If the input and output to the Switch layer both have size n×nn\times n, the number of parameter is 2tPn22tPn^{2} where PP is the number of squares that partition the input field and tt is the rank of the low-rank approximation.

4.3. NN for the forward map η→d→𝜂𝑑\eta\rightarrow d.

We move on to discuss the parameterization of the forward map η→d\eta\rightarrow d. The proposal is based on the simple observation that the inverse of the inverse map is the forward map.

More precisely, we simply reverse the architecture of the inverse map proposed in Algorithm 1. This results in an NN presented Algorithm 2. The basic architecture of this NN involves applying a few layers of Conv first, then followed by a Switch layer that mimics A≈UΣV∗A\approx U\Sigma V^{*}.

We would also like to mention yet another possibility to parameterize the forward map η→d\eta\rightarrow d, via a recurrent neural network . Let

5. Numerical results

In this section, we present numerical results of SwitchNet for far field pattern at a frequency ω≈60\omega\approx 60. The scatterer field η(x)\eta(x) supported in Ω=[−0.5,0.5]2\Omega=[-0.5,0.5]^{2} is assumed to be a mixture of Gaussians

In Algorithm 1, the parameters are specified as t=3t=3 (rank of the low-rank approximation), PX=82P_{X}=8^{2}, PD=42P_{D}=4^{2}, w=10w=10 (window size of the convolution layers), α=18\alpha=18 (channel number of the convolution layers), and L=3L=3 (number of convolution layers), resulting 3100K number of parameters. The parameters for Algorithm 2 are chosen to be t=4t=4, PX=82P_{X}=8^{2}, PD=42P_{D}=4^{2}, w=10w=10, α=24\alpha=24, and L=3L=3, with a total of 4200K parameters. Note that for both algorithms the number of parameters is significantly less than the one of a fully connected NN, which has at least 804=4096080^{4}=40960K parameters.

SwitchNet is trained with the ADAM optimizer in Keras with a step size of 0.002 and a mini-batch size of size 200. The optimization is run for 2500 epochs. Both the training and testing data sets are obtained by numerically solving the forward scattering problem with an accurate finite difference scheme with a perfectly matched layer. In the experiment, 12.5K pairs of (η,d)(\eta,d) are used for training, and another 12.5K pairs are reserved for testing. The errors are reported using the mean relative errors

Table 1 summarizes the test errors for Gaussian mixtures with different choices of nsn_{s}. For the purpose of illustration, we show the predicted dd and η\eta by SwitchNet along with the ground truth in Figure 5 for one typical test sample.

SwitchNet for seismic imaging

This section considers a two-dimensional model problem for seismic imaging. The scatterer η(x)\eta(x) is again assumed to be supported in a domain Ω\Omega with an O(1)O(1) diameter, after appropriate rescaling. Ω\Omega is discretized with a Cartesian grid X={x}x∈XX=\{x\}_{x\in X} at the rate of at least a few point per wavelength. Compared to the source and receiver configurations in Section 3.1, the experiment setup here is simpler. One can regard both S={s}s∈SS=\{s\}_{s\in S} and R={r}r∈RR=\{r\}_{r\in R} to be equal to a set of uniformly sampled points along a horizontal line near the top surface of the domain. The support of η\eta is at a certain distance below the top surface so that it is well-separated from the sources and the receivers (see Figure 6 for an illustration of this configuration).

The source and receiver operators in (9) take a particularly simple form. For the sources, the operator (G0ΠS)(G_{0}\Pi_{S}) is simply given by sampling:

Similarly for the receivers, the operator (ΠRTG0)(\Pi_{R}^{T}G_{0}) is given by

After plugging these two formulas back into (9), one arrives at the following representation of the observation data d(r,s)d(r,s) for r∈Rr\in R and s∈Ss\in S

2. Low-rank property

Following the approach taken in Section 3.2, we start with the linear approximation under the assumption that η(x)\eta(x) is weak. Since E=diag(η)E=\text{diag}(\eta), the first order approximation is

where the element AA at (r,s)∈R×S(r,s)\in R\times S and x∈Xx\in X is given by

Under the assumptions that the sources SS and receivers RR are well-separated from the support of η(x)\eta(x) and that c0(x)c_{0}(x) varies smoothly, the matrix AA satisfies a low-rank property similar to Theorem 1. To see this, we again partition XX into Cartesian squares X0,…,XPX−1X_{0},\ldots,X_{P_{X}-1} of side-length equal to 1/ω1/\sqrt{\omega}. Since R=SR=S is now the restriction of XX on the surface level, this partition also induces a partitioning for R×SR\times S. When c0(x)c_{0}(x) varies smoothly, it is shown (see for example ) that the restriction of the matrix [G0(r,x)]r∈R,x∈X[G_{0}(r,x)]_{r\in R,x\in X} (or [G0(s,x)]s∈S,x∈X[G_{0}(s,x)]_{s\in S,x\in X}) to each piece of the partitioning is numerically low-rank. Since the matrix AA is obtained by taking the Khatri-Rao product of [G0(r,x)]r∈R,x∈X[G_{0}(r,x)]_{r\in R,x\in X}, [G0(s,x)]s∈S,x∈X[G_{0}(s,x)]_{s\in S,x\in X}, the low-rank property is preserved with the guarantee that the rank at most squares in the worst case.

By following the same argument in Section 3.3, one can show that the matrix AA has a low-complexity matrix factorization A≈UΣV∗A\approx U\Sigma V^{*} of exactly the same structure as (29). The corresponding factorization for A∗A^{*} is A∗≈VΣ∗U∗A^{*}\approx V\Sigma^{*}U^{*}.

3. Neural networks

Based on the low-rank property in Section 4.2, we propose here SwitchNet for seismic imaging.

When the linear approximation is valid (i.e., (52) holds) η\eta can be obtained from dd via a filtered projection approach (or called migration in the seismic community)

where ϵI\epsilon I is a regularizing term. Since A∗A^{*} has a low-complexity factorization A∗≈VΣ∗U∗A^{*}\approx V\Sigma^{*}U^{*}, the application A∗A^{*} to a vector can be represented by a Switch layer.

Concerning the (A∗A+ϵI)−1(A^{*}A+\epsilon I)^{-1} term, note that

which, unlike (41), is no longer a translation-invariant kernel as the data gathering setup is not so. For example, even when the background velocity c0(x)=1c_{0}(x)=1, the different terms of the Green’s function G0(⋅)G_{0}(\cdot) in (55) scale like

which fail to give a translation-invariant kernel of form K(x−y)K(x-y). As a direct consequence, the operator (A∗A+ϵI)−1(A^{*}A+\epsilon I)^{-1} is not translation-invariant either.

In order to capture the loss of translation-invariance, we include an extra pointwise multiplication layer PM (defined in Section 3.4.2) when dealing with the inverse map. The pseudo-code of the NN for the inverse map is given in Algorithm 3.

3.2. NN for the forward map η→d→𝜂𝑑\eta\rightarrow d

As in Section 3.4.3, for the forward map from η→d\eta\rightarrow d, we simply reverse the architecture of the NN for the inverse map in Algorithm 3. For completeness we detail its structure in Algorithm 4. The main difference between Algorithm 2 and Algorithm 4 is again the inclusion of an extra pointwise multiplication layer.

4. Numerical results

In the numerical experiments, we set Ω=[−0.5,0.5]2\Omega=[-0.5,0.5]^{2} and discretize it by a 64×6464\times 64 Cartesian grid. As mentioned before, the sources SS and the receivers RR are located on a line near the top surface of Ω\Omega, similar to the setting in Fig. 6. This line is discretized uniformly with M=80M=80 points. Therefore, the size of η\eta and dd are 64×6464\times 64 and 80×8080\times 80, respectively. We assume a Gaussian mixture model for η\eta as in (49), where β=0.2,σ=0.015\beta=0.2,\sigma=0.015. Unlike before, the centers {ci}i=1ns\{c_{i}\}_{i=1}^{n_{s}} are kept away from the top surface of Ω\Omega in order to ensure that they are well-separated from the sources and receivers.

In Algorithm 3 and Algorithm 4, the parameters are set to be t=3t=3, PX=82P_{X}=8^{2}, PD=42P_{D}=4^{2}, N=64N=64, M=80M=80, w=8w=8, α=18\alpha=18, and L=3L=3, resulting NNs with 2900K parameters. The procedure of training the NNs is the same as the one used in Section 3.5. Table 2 presents the test errors for this model problem. The predicted and the ground truth d,ηd,\eta are visually compared in Figure 7 for one typical test sample.

Discussion

In this paper, we introduce a neural network, SwitchNet, for approximating forward and inverse maps arising from the time-harmonic wave equation. For these maps, local information at the input has a global impact at the output, therefore they generally require the use of a fully connected NN in order to parameterize them. Based on certain low-rank property that arises in the linearized operators, we are able to replace a fully connected NN with the sparse SwitchNet, thus reducing complexity dramatically. Furthermore, unlike convolutional NNs with local filters, the proposed SwitchNet connects the input layer with the output layer globally. This enables us to represent highly oscillatory wave field resulted from scattering problems, and to solve for the associated inverse problems.

Acknowledgments

The work of Y.K. and L.Y. is partially supported by the U.S. Department of Energy, Office of Science, Office of Advanced Scientific Computing Research, Scientific Discovery through Advanced Computing (SciDAC) program and the National Science Foundation under award DMS-1818449. Y.K. thanks Prof. Emmanuel Candès for the partial support from a Math+X postdoctoral fellowship. This work is also supported by the GCP Research Credits Program from Google.

References