Skip to content

1-Wasserstein (Métivier) misfit

Definition

For two 1-D probability densities \(f, g\) on \([0,T]\) with CDFs \(F, G\), the 1-Wasserstein distance reduces to

\[ W_1(f, g) \;=\; \int_0^T |F(t) - G(t)|\,\mathrm dt. \]

To apply this to signed seismic traces we first map them to densities with a positive transform \(\sigma\) (see positive argument): "square", "abs", "linear" (\(d + c\) with \(c \ge \max|d|\)), or "exp". The per-trace misfit is then \(W_1\) of the two resulting densities, summed over receivers/components/shots.

This is the 1-D per-trace form of the FWI misfit advocated by Métivier, Brossier, Mérigot, Oudet & Virieux (2016). Their full work also presents a \(d\)-dimensional dual KR formulation solved by proximal splitting — that is beyond the scope of this package and is typically only worth it for crosswell / VSP geometries where the 2-D shape of the gather matters more than the 1-D shape per trace.

Key property (anti-cycle-skipping)

For a translated Gaussian density (i.e. positive="square" on a translated Gaussian-modulated wavelet) shifted by \(\Delta t\),

\[ W_1 \;=\; |\Delta t|. \]

So the misfit is linear in the shift, smooth, and convex on the shift — exactly the cycle-skipping cure motivated by Métivier et al. (2016). This is tested explicitly in test_translation_invariance_property.

API

from sweep_loss import Wasserstein1Loss, w1_loss
Wasserstein1Loss(positive="square", dt=1e-3)(syn, obs)
w1_loss(syn, obs, positive="linear", dt=1e-3)

Tests

tests/test_w1.py checks:

  • zero for identical signals across all four positive transforms,
  • analytic identity \(W_1 = |\Delta t|\) for translated Gaussians to ~2 dt,
  • monotone growth with shift,
  • monotone across a range where L2 cycle-skips,
  • gradients flow,
  • parameter validation.

References

  • Métivier, L., Brossier, R., Mérigot, Q., Oudet, E. & Virieux, J. (2016). Measuring the misfit between seismograms using an optimal transport distance: application to full waveform inversion. Geophys. J. Int. 205 (1), 345-377. doi:10.1093/gji/ggw014
  • Engquist, B. & Froese, B. D. (2014). Application of the Wasserstein metric to seismic signals. Commun. Math. Sci. 12 (5), 979-988. doi:10.4310/CMS.2014.v12.n5.a7