---
title: Parametric Grid Convolutional Attention Networks
url: https://www.emergentmind.com/topics/parametric-grid-convolutional-attention-networks-pgcans
type: topic
---

# Parametric Grid Convolutional Attention Networks

Searching arXiv for the specified papers to ground the article in the cited literature.
Parametric Grid Convolutional Attention Networks (PGCANs) are neural architectures that combine grid-structured parameterization, localized convolution, and attention-based decoding or gating. In the formulation introduced for neural partial differential equation (PDE) solving, PGCANs are physics-informed networks designed to mitigate spectral bias by parameterizing the input domain with a trainable grid encoder whose vertex features are convolved, interpolated at query points, and mapped to the solution through an attention-based decoder, all trained without labeled data by minimizing physics residuals and boundary or initial condition losses [2403.15652]. Related work uses the same grid–convolution–attention pattern in graph classification and volumetric neuroimaging, where graph structure is normalized into a 2D grid or 3D feature maps are modulated by spatial attention, suggesting that PGCAN is best understood as an architectural family rather than a single fixed layer stack [1811.08270].

## 1. Architectural definition and parametric structure

In the PDE setting, PGCAN consists of three coupled components: a parametric grid encoder, a convolutional component acting on grid features, and an attention-based decoder. The encoder partitions the input space into cells on a single-resolution “mother” grid whose vertices carry trainable feature vectors. In two dimensions, the feature tensor is
$$
F_0 \in \mathbb{R}^{n_{\mathrm{rep}} \times N_f \times N_v^x \times N_v^y},
$$
where $n_{\mathrm{rep}}$ is the number of diagonally shifted grid repetitions, $N_f$ is the feature dimension, and $N_v^x \times N_v^y$ is the vertex lattice. The central design choice is locality: unlike fully connected networks whose parameters globally affect outputs, the grid parameterization restricts most interactions to nearby cells and vertices [2403.15652].

The convolutional stage applies a feature-wise $3 \times 3$ kernel with $\tanh$ activation to each feature map. For repetition $p$ and feature index $q$,
$$
F_c^{p,q,i_x,i_y} =
\tanh\!\left(\sum_{b=0}^{2}\sum_{a=0}^{2}
F_0^{p,q,i_x+a-1,i_y+b-1}\, W_q(a,b)\right),
$$
with $W_q \in \mathbb{R}^{3\times 3}$. This localized operator bidirectionally propagates information from boundaries into the interior, induces spatial coherence among neighboring vertices, and reduces parameter counts needed for fine resolutions by improving feature sharing through locality.

At a query point $x$, the convolved vertex features are mapped to a continuous representation by cosine-warped bilinear interpolation. If $\bar{x},\bar{y}$ are local cell coordinates normalized to $[0,1]^2$, the warp is
$$
\tilde{x}=\tfrac{1}{2}(1-\cos(\pi\bar{x})), \qquad
\tilde{y}=\tfrac{1}{2}(1-\cos(\pi\bar{y})).
$$
The interpolated feature for repetition $p$ is
$$
f^p(\tilde{x},\tilde{y})=
(1-\tilde{x})(1-\tilde{y}) f_{(0,0)}^p
+(1-\tilde{x})\tilde{y} f_{(0,1)}^p
+\tilde{x}(1-\tilde{y}) f_{(1,0)}^p
+\tilde{x}\tilde{y} f_{(1,1)}^p,
$$
and the aggregate encoding is
$$
f(x)=\sum_{p=1}^{n_{\mathrm{rep}}} f^p(x).
$$
The feature vector is split into two equal parts, $f_1(x)$ and $f_2(x)$, which are passed to the decoder.

The decoder uses gated mixing and self-attention. With $\phi_1=f_1(x)$ and $\phi_2=f_2(x)$,
$$
h^{1}=\sigma(W^{z,1}\phi_1+b^{z,1}), \qquad
z^{k}=\sigma(W^{z,k} h^k+b^{z,k}),
$$
$$
h^{k+1}=(1-z^k)\odot \phi_1+z^k\odot \phi_2,
\qquad
\hat{u}(x)=W h^{L+1}+b.
$$
Self-attention is introduced through scaled dot-product attention,
$$
\mathrm{Attn}(Q,K,V)=\mathrm{softmax}(QK^\top/\sqrt{d})V,
$$
with learned projections of encoded features. In the PDE formulation, the stated role of self-attention is to focus training signal on cells or features where residuals are large, including high-frequency or high-gradient regions.

This parametric structure has different realizations in other domains. In motif-based graph classification, the parametric components are the convolution kernels, attention parameters, and classifier, while graph-to-grid normalization is fixed preprocessing [1811.08270]. In 3D neuroimaging, the parametric components are a compact 3D CNN plus spatial attention gates computed by learnable $1\times1\times1$ convolutions conditioned on global context [2011.09115]. This suggests that “parametric” does not necessarily mean that the grid itself is learned; rather, it denotes that the convolutional and attentional operators acting on grid-structured representations are learned.

## 2. PDE formulation and training objective

The PDE formulation treated by PGCAN is stated generically as
$$
\mathcal{N}[u](x)=0, \qquad x\in\Omega,
$$
with boundary condition
$$
\mathcal{B}[u](x)=g(x), \qquad x\in\partial\Omega.
$$
For time-dependent problems, the more general form is
$$
\mathcal{N}_{x,t}[u(x,t)] = f(x,t), \qquad
u(x,0)=h(x), \qquad
u(x,t)|_{\partial\Omega}=g(x,t).
$$
Training is label-free in the domain: PGCAN minimizes a physics residual loss and boundary or initial condition losses rather than fitting supervised solution pairs [2403.15652].

For a collocation set $\mathcal{X}\subset\Omega$, the residual loss is
$$
\mathcal{L}_{\mathrm{res}}=
\frac{1}{|\mathcal{X}|}\sum_{x\in\mathcal{X}}
\big\|\mathcal{N}[u_\theta](x)\big\|^2.
$$
For a boundary collocation set $\partial\mathcal{X}\subset\partial\Omega$,
$$
\mathcal{L}_{\mathrm{bc}}=
\frac{1}{|\partial\mathcal{X}|}\sum_{x\in\partial\mathcal{X}}
\big\|\mathcal{B}[u_\theta](x)-g(x)\big\|^2.
$$
For time-dependent problems, the initial condition loss is
$$
\mathcal{L}_{\mathrm{ic}}=
\frac{1}{|\mathcal{X}_{\mathrm{ic}}|}\sum_{x\in\mathcal{X}_{\mathrm{ic}}}
\big\|u_\theta(x,0)-h(x)\big\|^2.
$$
The total loss is
$$
\mathcal{L}=
\lambda_{\mathrm{res}}\mathcal{L}_{\mathrm{res}}+
\lambda_{\mathrm{bc}}\mathcal{L}_{\mathrm{bc}}+
\lambda_{\mathrm{ic}}\mathcal{L}_{\mathrm{ic}},
$$
with dynamic weight balancing rather than an explicit spectral penalty.

The balancing rule is designed to align the gradient magnitudes of auxiliary losses with the PDE residual:
$$
\hat{\lambda}_i=
\frac{\max_{\theta_n}\|\nabla_\theta \mathcal{L}_{\mathrm{res}}(\theta_n)\|}
{\overline{\|\nabla_\theta \mathcal{L}_i(\theta_n)\|}},
\qquad
\lambda_i \leftarrow (1-\alpha)\lambda_i+\alpha\hat{\lambda}_i,
$$
where $i\in\{\mathrm{bc},\mathrm{ic}\}$. The stated purpose is to prevent PDE residuals from dominating training dynamics and thereby underfitting boundary or initial conditions.

The implementation guidance given for PGCAN follows a specific sequence. One defines the PDE operator $\mathcal{N}[\cdot]$, boundary operator $\mathcal{B}[\cdot]$, domain $\Omega$, and collocation sets; initializes grid features, convolution kernels, and decoder parameters; resamples interior and boundary points periodically; computes interpolated features and decoder outputs at collocation points; forms residual and BC or IC losses; updates the dynamic weights; and optimizes all learnable parameters with Adam. The recommended settings repeatedly used across benchmarks are a $9\times9$ grid, $N_f=128$, $n_{\mathrm{rep}}=2$, a 3-layer decoder with 64 neurons per layer, and a total of approximately $35$k trainable parameters for scalar outputs.

## 3. Spectral bias, locality, and frequency-domain diagnosis

The motivating problem for PGCAN is spectral bias in neural PDE solvers. Spectral bias is described as the tendency of standard deep neural networks, especially fully connected feed-forward networks used in vanilla physics-informed neural networks (PINNs), to learn low-frequency components first while struggling with high-frequency features and localized sharp gradients. In PDE contexts, this leads to poor approximation of oscillatory solutions, stiff responses, and boundary-layer gradients, precisely where fidelity is often most consequential [2403.15652].

The mechanism proposed in the PGCAN paper has three parts. First, local parameterization reduces the global coupling induced by shared parameters in fully connected networks. Second, convolution introduces spatial coherence, suppresses salt-and-pepper overfitting, and improves propagation of informative gradients from boundaries and initial conditions into interior regions. Third, attention selectively emphasizes features associated with large residuals or high curvature, steering optimization toward the hard components of the solution. No formal theorems are provided; the paper explicitly presents these as theoretical insights supported by empirical behavior and notes that the observations align with NTK-informed views of gradient pathologies in PINNs.

To quantify spectral bias, the paper introduces a directional power spectral density (PSD) analysis of the error field. Given an error “image” $E(x,y)$, one computes the discrete Fourier transform and its power
$$
P(u,v)=|F(u,v)|^2.
$$
The power is averaged along axes to obtain directional PSD curves, and the curves are normalized to start at a common initial value so that they reflect the distribution of error across frequencies rather than total power. The interpretive criterion is explicit: flatter curves indicate weaker spectral bias. In this frequency-domain view, PGCAN’s directional PSD curves are reported as consistently flatter than those of vPINN, PIXEL, and often M4, while also having lower overall error power.

A common misunderstanding is to equate spectral-bias mitigation with the addition of a frequency-domain regularizer. That is not the mechanism used here. The work states that there is no explicit spectral penalty; the mitigation is attributed to architectural locality, convolutional regularization, attention-based prioritization, and dynamic balancing of loss terms. Another potential misunderstanding is that performance gains come primarily from scale. The reported parameter counts are comparatively modest relative to PIXEL, and the paper explicitly argues that the gains stem from architecture rather than brute-force parameter growth.

## 4. Benchmarks, quantitative results, and operating regime

The PDE benchmarks cover one-dimensional, two-dimensional, and irregular three-dimensional domains. The tested systems are Burgers’ equation with periodic boundary conditions for $\nu=1/\pi$ and $\nu=0.01/\pi$; one-dimensional convection or advection with periodic boundary conditions for $\beta=5$ and $\beta=30$; the two-dimensional Helmholtz equation with Dirichlet boundary conditions for $a^2=1$ and $a^2=10$; the two-dimensional lid-driven cavity problem for incompressible Navier–Stokes with moving top lid amplitude $A\in\{1,5\}$; and Poisson’s equation on a 3D torus defined by
$$
(1-\sqrt{x^2+y^2})^2+z^2=0.5^2
$$
with prescribed boundary values [2403.15652].

The training protocol is also fixed across experiments: Adam with initial learning rate $10^{-3}$, reduced by $90\%$ every $10$k epochs, for a total of $50$k epochs. The sampling scheme typically uses $20$k interior points resampled every $100$ epochs, except for the lid-driven cavity case, which uses $5$k interior points. Dynamic weights are updated every $100$ epochs, except for Helmholtz, where they are updated every epoch.

| Benchmark | PGCAN median relative $L_2$ error | Comparator errors |
|---|---:|---|
| Burgers, $\nu=1/\pi$ | $2.90\mathrm{e}{-3}$ | M4 $2.91\mathrm{e}{-3}$; PIXEL $6.46\mathrm{e}{-2}$; vPINN $7.55\mathrm{e}{-3}$ |
| Burgers, $\nu=0.01/\pi$ | $1.45\mathrm{e}{-2}$ | M4 $1.38\mathrm{e}{-2}$; PIXEL $8.26\mathrm{e}{-2}$; vPINN $1.49\mathrm{e}{-2}$ |
| Convection, $\beta=5$ | $9.05\mathrm{e}{-4}$ | M4 $8.07\mathrm{e}{-4}$; PIXEL $1.49\mathrm{e}{-3}$; vPINN $1.27\mathrm{e}{-3}$ |
| Convection, $\beta=30$ | $7.77\mathrm{e}{-3}$ | M4 $6.51\mathrm{e}{-1}$; PIXEL $1.57\mathrm{e}{-1}$; vPINN $1.27\mathrm{e}{-1}$ |
| Helmholtz, $a^2=1$ | $5.94\mathrm{e}{-4}$ | M4 $1.23\mathrm{e}{-3}$; PIXEL $3.44\mathrm{e}{-2}$; vPINN $9.07\mathrm{e}{-3}$ |
| Helmholtz, $a^2=10$ | $2.70\mathrm{e}{-3}$ | M4 $6.25\mathrm{e}{-2}$; PIXEL $2.37\mathrm{e}{-1}$; vPINN $1.73\mathrm{e}{+0}$ |
| Lid-driven cavity, $A=1$ | $1.22\mathrm{e}{-3}$ | M4 $1.19\mathrm{e}{-2}$; PIXEL $2.56\mathrm{e}{-1}$; vPINN $3.84\mathrm{e}{-2}$ |
| Lid-driven cavity, $A=5$ | $1.42\mathrm{e}{-2}$ | M4 $2.79\mathrm{e}{-1}$; PIXEL $6.25\mathrm{e}{-1}$; vPINN $6.61\mathrm{e}{-1}$ |

These results are reported as median relative $L_2$ errors after $50$k epochs. The stated pattern is that PGCAN maintains accuracy as frequency and gradient complexity increase, with especially large margins in high-frequency regimes such as advection with $\beta=30$, Helmholtz with $a^2=10$, and large-gradient fluid flow in the lid-driven cavity. The complexity and memory discussion reinforces the same point: PGCAN uses a small grid and small $n_{\mathrm{rep}}$, convolution is lightweight because it is feature-wise with $3\times3$ kernels, and inference remains fast due to local interpolation and a shallow decoder.

The ablation and sensitivity observations delimit the operating regime. Removing convolution in parametric grids is said to increase overfitting and slow boundary information propagation. Increasing model size alone in M4 or vPINN does not recover PGCAN’s performance in the lid-driven cavity problem. As $\nu$ decreases in Burgers’ equation and frequency grows in advection and Helmholtz, PGCAN’s errors increase more modestly than those of baselines, although very small $\nu$ can slightly degrade global accuracy because the grid is uniform. Comparing with refined finite-element solutions, the paper further reports that model errors converge as the reference discretization stabilizes, which it interprets as grid-resolution invariance of the continuous decoder even though the encoder itself is grid-parameterized.

## 5. Related instantiations in graph learning and neuroimaging

A graph-classification architecture that the source material explicitly uses to contextualize PGCAN is motif-based attention graph convolutional neural networks (MA-GCNN). In that setting, an arbitrary graph is first normalized into a 2D node grid by selecting central nodes with closeness centrality, extracting BFS neighborhoods, enumerating two-hop path motifs, and arranging the matched motifs into a canonical matrix. The resulting tensor
$$
Z \in \mathbb{R}^{3N \times W \times d}
$$
is then processed by CNN-style layers and subgraph-level self-attention [1811.08270].

The first graph convolution uses a $3\times1$ kernel with horizontal stride $3$ and vertical stride $1$ so that each motif-length band is convolved as a unit. The second also uses a $3\times1$ kernel, with horizontal stride $1$ and vertical stride $3$. Subgraph features are flattened and passed to additive or dot-product attention. In the additive formulation,
$$
e_{ij}=\mathrm{LeakyReLU}\!\left(a^\top[Wh_{c_i}\Vert Wh_{c_j}]\right),\qquad
\alpha_{ij}=\mathrm{softmax}_{j\neq i}(e_{ij}),
$$
and multi-head averaging yields a weighted representation of each subgraph. The source material is explicit that the graph-to-grid normalization is non-parametric, whereas the convolutions, attention weights, and classifier are learned. It therefore presents MA-GCNN as embodying the core design of a PGCAN in the graph domain.

A second related instantiation is the 3D Grid-Attention network for age prediction and Alzheimer’s disease classification from structural MRI. Here the grid is volumetric rather than graph-normalized. A shallow 3D CNN backbone with four convolutional blocks and channel progression $[32,64,64,128,128]$ is augmented by two spatial attention modules placed after convolutions $3$ and $4$, denoted A1 and A2 [2011.09115].

For a local feature map $X_l$ and global context feature map $G$ from the final convolution, the attention gate is
$$
S_l=\sigma(W_f*X_l + W_g*\mathrm{Up}(G)),
$$
$$
\alpha_l=\psi*S_l,\qquad
\hat{\alpha}_l=\frac{\alpha_l-\min(\alpha_l)}{\sum \alpha_l},\qquad
X'_l=\hat{\alpha}_l\odot X_l.
$$
The projections $W_f$, $W_g$, and $\psi$ are all $1\times1\times1$ convolutions, with $C_{\mathrm{int}}=64$ for A1 and $C_{\mathrm{int}}=128$ for A2. Predictions from the backbone, A1 head, and A2 head are averaged. The salience maps are the normalized attention masks themselves, making the attention native rather than post hoc.

The empirical results in that neuroimaging setting are concrete. On cognitively normal test subjects, the brain-age model reports $\mathrm{MAE}=3.96$ years, $\mathrm{RMSE}=5.17$, and correlation $=0.686$. The AD classification model reports accuracy $=0.868$, balanced accuracy $=0.84$, precision $=0.81$, and recall $=0.76$. Average Jaccard overlap between age and AD salience is higher for the lower-level attention module A1 than for A2; for example, at the threshold $\mu+0.5\sigma$, A1 is $0.52/0.52$ for CN/AD and A2 is $0.10/0.20$. The qualitative interpretation given is that age prediction relies on more widespread features, whereas AD classification emphasizes ventricular regions.

Taken together, the graph and MRI cases show that the grid–convolution–attention template is not confined to PDE solving. The grid may arise from motif-guided normalization of an arbitrary graph, from volumetric CNN feature maps, or from a trainable coordinate-domain parameterization. This suggests a unifying viewpoint in which PGCAN denotes a family of architectures that preserve spatial structure, exploit local convolutional inductive bias, and use parametric attention to weight spatial or subgraph-level evidence.

## 6. Limitations, misconceptions, and future directions

The PDE formulation has several stated limitations. Uniform grids may underresolve highly localized shocks or discontinuities, so learning can focus on small regions and slightly degrade global accuracy. The paper suggests that adaptive meshes or hierarchical encoders with multi-resolution grids could better allocate parameters spatially [2403.15652]. Excessively large $n_{\mathrm{rep}}$ or high-resolution grids can overfit, as illustrated by the contrast with PIXEL, and PGCAN explicitly avoids that regime through small $n_{\mathrm{rep}}$ and convolution.

The theoretical status of the method is also carefully delimited. The paper offers mechanistic explanations for why local parametric encoding, convolution, and attention should reduce spectral bias, but it does not provide formal theorems. Any stronger claim would therefore exceed the evidence presented. A plausible implication is that PGCAN presently occupies an empirically grounded middle ground: its behavior is motivated by architectural reasoning and supported by benchmark results, but not yet characterized by a complete theory.

The domain-general extensions carry their own constraints. In the graph setting, the method assumes that two-hop path motifs and closeness centrality are appropriate organizing primitives; if those assumptions fail, the source material suggests that learned positional encodings or multi-motif vocabularies may be needed [1811.08270]. In the MRI setting, all scans are $3$T and no explicit inter-scanner harmonization is applied, so external validation across scanners and populations remains future work; the same source proposes domain adaptation and harmonization as next steps and notes that the models are single-task rather than joint age–diagnosis models [2011.09115].

Several misconceptions can therefore be ruled out. PGCAN is not synonymous with a transformer-only model, because convolution and locality are central to the design. It is not merely a parametric grid without attention, because attention is explicitly used to prioritize salient features or spatial positions. It is not restricted to regular Euclidean image domains, since the PDE work includes an irregular 3D torus and the graph work uses deterministic graph-to-grid normalization. Nor is it a purely supervised method, because the PDE solver is trained without labeled solution data in the domain.

The forward-looking directions stated across the sources are consistent. For PDEs, adaptive grids, hierarchical encoders, explicit physics-informed attention, hybrid spectral–grid encoders, and extensions to very high-dimensional PDEs and complex geometries are proposed. For neuroimaging, multi-task learning, mild cognitive impairment, and cross-scanner generalization via harmonization and domain adaptation are proposed. The recurring theme is that grid-convolution-attention architectures are most compelling when local structure matters, but the grid itself may need to become more adaptive as geometry, dimensionality, or heterogeneity increase.

Source: https://www.emergentmind.com/topics/parametric-grid-convolutional-attention-networks-pgcans