Level 0: Foundation
★☆☆☆☆ Introductory⏱ 5 minGeneral audience. No mathematics required.Attention that knows which way is up, and which way is left
Your left and right hands have exactly the same distances between corresponding points, yet they are different. Many drug molecules come in left- and right-handed forms with different effects. A network that looks only at distances cannot tell them apart. The SE(3)-Transformer passes vectors and higher-order features between points and combines them in ways that respect rotations, but not reflections, so it can. The demo counts the spherical-harmonic functions it uses up to degree L.
Equivariant attention models predict molecular properties and protein structure (AlphaFold 2’s structure module uses related invariant-point attention), and model 3-D physical systems where orientation matters.
- 1. Left and right hands have…
- 2. Distance-only networks can tell mirror images apart:
- 3. SE(3) means…
Level 1: Beginner
★★☆☆☆ Basic⏱ 20 minSecondary-school mathematics: arithmetic and elementary algebra.By hand
- Irreducible representations: under 3-D rotation, degree-ℓ features have 2ℓ + 1 components (1, 3, 5, 7, …) and rotate by Wigner D-matrices. Up to degree L there are (L + 1)² spherical-harmonic functions.
- Tensor products: combining degrees ℓ₁ and ℓ₂ yields degrees |ℓ₁ − ℓ₂| … ℓ₁ + ℓ₂ (Clebsch–Gordan). For example 1 ⊗ 1 = 0 ⊕ 1 ⊕ 2: the dot product, the cross product and a traceless matrix (dimensions 1 + 3 + 5 = 9 = 3 × 3).
- Equivariant attention:
- queries and keys combine into invariant attention logits (degree-0);
- values are equivariant features of any degree;
- the output is a weighted sum, so it stays equivariant.
- Kernels: values are computed with filters W(x_j − x_i) = Σ radial(‖r‖) × spherical harmonics(r̂) × CG coefficients (Tensor Field Network style).
- Pseudo-scalars: a · (b × c) is rotation-invariant but flips sign under reflection: the signature of handedness.
- 1. Components of a degree-2 feature:
- 2. 1 ⊗ 1 decomposes into degrees…
- 3. Spherical harmonics up to degree 3:
Level 2: Intermediate
★★★☆☆ Intermediate⏱ 25 minUndergraduate students and practising engineers.SE(3)-Transformers in code
Exercise 1.
- Degree-1 features rotate like vectors.
- Degree-2 features rotate like traceless matrices.
- The triple product is invariant under rotation and flips under reflection.
Practice.
- Use the e3nn library (irreps, spherical harmonics and tensor products, with optional parity), NVIDIA’s DGL SE(3)-Transformer, or Equiformer.
- Keep the maximum degree small (ℓ ≤ 2 or 3); tensor-product cost grows steeply with degree.
- Restrict attention to k nearest neighbours or a radius cutoff.
- Decide whether parity should be respected: O(3) for achiral physics, SE(3) when handedness matters.
from e3nn import o3
irreps_in, irreps_sh = o3.Irreps("8x0e + 4x1o"), o3.Irreps.spherical_harmonics(2)
tp = o3.FullyConnectedTensorProduct(irreps_in, irreps_sh, o3.Irreps("8x0e + 4x1o + 2x2e"))
sh = o3.spherical_harmonics(irreps_sh, edge_vec, normalize=True)
msg = tp(node_feat[src], sh, weight=radial_mlp(edge_len)) # equivariant message- 1. A standard library for equivariant networks:
- 2. Maximum degree is usually kept…
- 3. If handedness matters, use…
Level 3: Advanced
★★★★☆ Advanced⏱ 25 minGraduate level, with full derivations and proofs.Theory
Equivariance of attention. If logits α_ij are invariant and values v_ij transform by D(R), then Σ softmax(α)_ij v_ij also transforms by D(R), since the weights are unchanged and the sum is linear.
Why reflections matter. E(3)-invariant functions of a point set depend only on its distances, so they take equal values on mirror images. An SE(3)-equivariant network can form pseudo-scalars, such as a · (b × c), from three vectors via tensor products (1 ⊗ 1 → 1, then 1 ⊗ 1 → 0). These distinguish handedness.
Cost and alternatives. Tensor products with degree up to L cost roughly O(L⁶) per edge naively (O(L³) with modern tricks), which drove simpler designs. EGNN uses only scalars and vectors; PaiNN and NequIP use limited degrees; MACE uses higher-body messages efficiently.
- 1. Attention stays equivariant because logits are…
- 2. E(3)-invariant features of mirror images are…
- 3. A pseudo-scalar can be built as…
Level 4: Expert
★★★★★ Expert⏱ 30 minResearchers: original papers and open problems.Can an SE(3)-equivariant model tell mirror images apart when a distance-based one cannot?
History.
- F. B. Fuchs, D. E. Worrall, V. Fischer and M. Welling, “SE(3)-Transformers: 3D roto-translation equivariant attention networks” (NeurIPS 2020).
- Builds on Tensor Field Networks (Thomas et al., 2018).
Exercise 2.
- Data: 6-point helices (1.5π turn), left- or right-handed, with noise 0.05 and a random rotation. The classes are exact mirror images.
- Features:
- distance-only (E(3)-invariant, EGNN-like) random features;
- a simplified SE(3) attention layer: 3 heads with attention weights from distances and degree-1 values x_j − x_i, giving 3 equivariant vectors per point. The readout uses their norms, dot products and triple product;
- the same SE(3) layer with the triple product removed.
- Classifier: linear.
- Simplification: this is a single degree-1 attention layer with an invariant readout, not the full multi-degree SE(3)-Transformer.
| features | accuracy |
|---|---|
| distance-only (E(3)) | 0.465 |
| SE(3) attention without triple product | 0.465 |
| SE(3) attention with triple product | 1.000 |
| symmetry check | value |
|---|---|
| vector output, rotation error | 1.8e-15 |
| triple product, rotation error | 1.8e-15 |
| triple product, reflected + original | 0.0 (sign flips exactly) |
- Reflection-invariant features are at chance, as theory requires: distances, norms and dot products are identical for mirror images.
- One pseudo-scalar is enough: the triple product of equivariant attention outputs separates the hands perfectly.
- Seeds: seeds 1 and 2 gave SE(3) 0.983/0.975, distance-only 0.507/0.507, no triple product 0.49/0.517.
SE(3)-Transformers in AI, robotics and aerospace
- Drug discovery: properties of chiral molecules, docking and generation.
- Protein structure: equivariant attention in structure modules.
- Robotics: 6-DoF grasp and pose prediction from point clouds, where outputs must rotate with the scene.
- Design lesson: choose the symmetry group carefully. Too much symmetry (reflections) can erase the very property you need.
References
- F. B. Fuchs, D. E. Worrall, V. Fischer and M. Welling (2020). “SE(3)-Transformers: 3D roto-translation equivariant attention networks.” NeurIPS.
- N. Thomas et al. (2018). “Tensor field networks: rotation- and translation-equivariant neural networks for 3D point clouds.” arXiv:1802.08219.
- M. Geiger and T. Smidt (2022). “e3nn: Euclidean neural networks.” arXiv:2207.09453.