Many vision systems output heatmaps: coarse grids of scores, usually at a quarter of image resolution, where each cell says how likely a body joint is to be there. A natural way to track joints through video, or to fuse several camera views, is to treat each heatmap as a likelihood over a continuous joint position. That likelihood is then combined with a smooth motion prior using Expectation Propagation (EP). EP is an approximate Bayesian method that repeatedly swaps one observation's contribution for a Gaussian stand-in. It does this by matching the mean and variance of a "hybrid" distribution: the current belief with that observation removed, multiplied by the true likelihood. In practice those moments are computed by summing over grid cells, as if all the heatmap mass sat at cell centres. This note argues that the grid sum is a specific, analyzable source of EP instability. When the belief with the observation removed (the "cavity") becomes narrower than one grid cell, the grid-sum hybrid collapses onto one or two cell centres. The computed variance goes to nearly zero, and the Gaussian stand-in gets an almost infinite precision. That overconfident factor pins the chain and makes later updates oscillate or produce negative variances.
The proposed fix is to compute EP moments exactly against a continuous interpolant of the heatmap: each cell is treated as a constant-likelihood patch, so the hybrid becomes a Gaussian cut into cell-shaped pieces, and its moments have closed forms in Gaussian cumulative distribution functions. This matters beyond pose. The same mismatch between a continuous latent state and a gridded observation appears in voxel detectors and in location-token models. The pose literature has noticed a closely related collapse inside neural training, "activation shrinkage", but has never tied it to inference convergence.
Core Claim
Consider one keypoint coordinate with cavity $\mathcal{N}(m, s^2)$ and a heatmap with cell width $h$ and normalized cell values $w_j$. The grid-sum hybrid places weight $w_j\,\mathcal{N}(c_j; m, s^2)$ on each cell centre $c_j$. The piecewise-constant hybrid instead integrates the cavity over each cell interval $[a_j, a_j+h]$:
$$ \mu = \frac{\sum_j w_j \int_{a_j}^{a_j+h} x\,\mathcal{N}(x;m,s^2)\,dx}{\sum_j w_j \int_{a_j}^{a_j+h} \mathcal{N}(x;m,s^2)\,dx}, $$
and the second moment has the same form, with $x^2$ in place of $x$. Both are sums of Gaussian cumulative distribution function and density terms, so they are exact and cheap. The site precision EP produces is $\lambda = 1/v - 1/s^2$, where $v$ is the hybrid variance.
The claim has three parts.
- Direction of the bias. The grid-sum $v$ is biased in a direction that depends on the ratio $s/h$. When $s \gg h$ it is slightly inflated; Sheppard-style reasoning about binned variances predicts an excess of order $h^2/12$. When $s \lesssim h$ it collapses toward zero, while the interval-exact $v$ stays bounded below by the variance of a Gaussian truncated to one cell.
- Where failures occur. EP non-convergence on heatmap likelihoods concentrates in the regime $s/h \lesssim 1$. That regime is exactly where a good motion prior pushes the cavity: confident tracking on clean frames.
- The remedy. Interval-exact moments, combined with the cavity-mean linearization of State Space Expectation Propagation for nonlinear camera projections, remove most of these failures without damping heuristics. They also give calibrated per-joint uncertainty from the heatmap itself.
Relation to Prior Work
The pose-estimation line motivates the problem.
- Integral Human Pose Regression replaced argmax with the grid expectation (soft-argmax). It removed the stride bottleneck that Towards Accurate Multi-person Pose Estimation in the Wild identified, but it keeps only the first moment.
- Dive Deeper Into Integral Pose Regression showed that on clean images the learned heatmap shrinks to one or two pixels, which hurts the grid expectation. Its remedy is a fixed isotropic Gaussian prior with $\sigma=2$.
- Localization with Sampling-Argmax and Heatmap Distribution Matching for Human Pose Estimation reshape the heatmap during training, using continuous basis kernels with Gumbel sampling and Sinkhorn optimal transport respectively. At test time both still decode a single deterministic point.
All four change how the network is trained or decoded per frame. None treats the heatmap as a likelihood inside iterative inference, so none can observe the convergence failure studied here. We keep their networks fixed and change the inference.
The inference line both constrains and supplies the method.
- Failure modes to explain. Negative site variances and oscillation under non-log-concave likelihoods are documented in Fast Bayesian Inference for Non-Conjugate Gaussian Process Regression, Gaussian process regression with Student-t likelihood and Approximate Expectation Maximization. Multimodal heatmaps are such likelihoods, so part of the failure is not about quantization at all. Our analysis must separate the two causes.
- Nonlinear projections and scaling. State Space Expectation Propagation supplies linear-time Kalman-style EP over temporal priors and the cavity-mean linearization, which we reuse for projecting a 3D joint into each camera. That work used low-dimensional point processes and inducing points, never dense image grids.
- Guaranteed-convergent alternatives. Fast Convergent Algorithms for Expectation Propagation Approximate Bayesian Inference (a double-loop EP) and Khan et al.'s concave-bound coordinate ascent both guarantee convergence. They are the principled competitors, and our moment computation can be plugged into either.
- Sampled-moment noise. ABC-EP shows that noisy moment estimates alone can stop EP converging. Grid quantization is a deterministic analogue of that noise.
Research Program
Analysis. We derive the grid-sum and interval-exact hybrid variances as functions of $s/h$ and the sub-cell offset of $m$. We then characterize when the grid-sum site precision exceeds a stable bound. In a scalar chain model we show how one near-infinite site precision propagates into negative cavities for its neighbours under sequential updates. We state a sufficient condition for convergence with interval-exact moments for unimodal cell profiles, and verify it numerically where a proof is out of reach.
Algorithm. Interval-exact moment matching extends to 2D by working per axis when the cavity covariance is axis-aligned. Otherwise it uses a few Gauss–Hermite nodes per occupied cell, restricted to cells within four cavity standard deviations. This keeps cost comparable to a soft-argmax. A bilinear interpolant variant is tested as an ablation.
Systems. We build two systems on frozen, publicly trained heatmap backbones:
- 2D temporal tracker. Each joint coordinate follows a Matérn-3/2 temporal prior. Inference uses state-space EP over single-camera video.
- Multi-view 3D fuser. A 3D joint with a temporal prior is observed through each camera's heatmap. Each projection is linearized at the cavity mean, and the interval-exact moments are computed in the image plane.
Secondary question. Does cavity-informed decoding make activation shrinkage harmless? If the motion prior supplies the spread that Dive Deeper Into Integral Pose Regression had to impose by hand, then sharp heatmaps should become an advantage rather than a liability.
Baselines
Per-frame soft-argmax, the naive reference. This is decoding with Integral Human Pose Regression on the same backbone, with no temporal or cross-view inference. It anchors how much any inference adds. The paper reports 49.6 mm Mean Per Joint Position Error (MPJPE) on Human3.6M for its full training pipeline. We re-measure our own backbone rather than compare against that number directly.
Kalman smoothing on soft-argmax points. This is the strongest cheap competitor. Each frame's soft-argmax coordinate is treated as a Gaussian measurement whose variance is either fixed or taken from the heatmap's grid second moment. The measurements are run through the same state-space smoother as our method. It is convergent by construction and costs almost nothing. Beating it requires that exact moments carry information a point estimate throws away, above all under occlusion and in bimodal frames. We found no reported result on Lacuna for heatmap-driven temporal smoothing on Human3.6M, so we produce this number ourselves.
Grid-sum EP with damping. This is exactly our system with cell-centre moments. It is the ablation that isolates the key ingredient. We tune the damping schedule and the number of sweeps with the same grid-search budget as our method, and report divergence rate alongside accuracy.
Convergent inference with grid-sum moments. Both the double-loop EP of Fast Convergent Algorithms for Expectation Propagation Approximate Bayesian Inference and natural-gradient variational inference in the dual form of Improving Hyperparameter Learning under Approximate Inference in Gaussian Process Models are run on the same prior and heatmaps. Both avoid divergence by construction, so they are the real test of whether fixing moments beats fixing the optimizer.
Per-frame accuracy reference. For per-frame 2D accuracy we quote 71.4 COCO AP for integral regression with the spatial prior, from Dive Deeper Into Integral Pose Regression. Our per-frame decoding with a flat cavity should not fall below its backbone's equivalent.
Beating the field means three things at once:
- lower MPJPE than the Kalman-on-points baseline on the occluded-frame subset;
- a divergence rate near zero where damped grid-sum EP fails;
- better-calibrated per-joint variances than both convergent competitors, all at matched wall-clock cost.
Why not just…?
Why not just use higher-resolution heatmaps? Upsampling the heatmap before summing shrinks $h$ and pushes the collapse threshold down. It never removes the threshold, because a confident prior can always make $s$ smaller still, and cost grows with the square of the upsampling factor. The piecewise-constant interpolant is exactly the infinite-upsampling limit of nearest-neighbour upsampling. We will run ×2, ×4 and ×8 bilinear upsampling with grid sums and plot divergence rate against compute. If ×2 already matches our method at similar cost, the contribution shrinks to an analysis result, and we will say so.
Why not just smooth soft-argmax outputs with a Kalman filter? This is the most serious threat, and it is a primary baseline. Its weakness should appear in bimodal frames: symmetric limbs and occlusion. There the soft-argmax lands between peaks, as Dive Deeper Into Integral Pose Regression and the integral-regression literature note, and no measurement variance can repair a wrong mean. The cavity, by contrast, selects the peak consistent with the motion. If the gap on occluded frames is within noise, EP over heatmaps is not worth its cost.
Why not just use variational inference, which always converges? Variational inference with grid-sum expected log-likelihoods will not diverge. It is, however, known to underestimate variance, and Improving Hyperparameter Learning under Approximate Inference in Gaussian Process Models shows its objective biases hyperparameters: best or tied log predictive density on 13 of 27 UCI datasets versus 16 for the hybrid. The interval-exact integrals also improve variational inference's expected log-likelihood, so we report variational inference both with and without them. The question is then settled empirically on calibration, measured as the coverage of predicted joint ellipses.
Why not just apply Sheppard's correction to the grid variance? Subtracting $h^2/12$ is valid only when the density is smooth across cells. That is the $s \gg h$ regime. For $s \lesssim h$ it makes the already-collapsed variance worse. It is a one-line ablation.
Proposed Experiments
Controlled synthetic study. We render smooth and bimodal ground-truth likelihoods, rasterize them at strides 4 and 8, and sweep the prior's strength so that $s/h$ spans 0.1 to 10. Exact hybrid moments come from fine quadrature. We measure moment error, site-precision error, and divergence rate for grid-sum versus interval-exact EP. The decisive check is whether grid-sum divergence concentrates below $s/h \approx 1$ and disappears with exact moments on unimodal likelihoods. On bimodal likelihoods it should remain, which would attribute that residual to non-log-concavity rather than quantization.
Human3.6M video. We run the 2D temporal tracker per camera and the four-camera 3D fuser on frozen heatmap backbones. We report MPJPE overall and on frames where a joint's heatmap is multimodal, together with the divergence rate, the number of EP sweeps, and 50%/90% coverage of predicted uncertainty ellipses. Every method gets the same backbone, the same prior hyperparameters, and the same tuning budget. The prior hyperparameters are learned with the EP marginal likelihood for all methods, following Improving Hyperparameter Learning under Approximate Inference in Gaussian Process Models.
Activation-shrinkage test. We use MPII at [email protected] and COCO still images, where Integral Human Pose Regression reports 17.2% (standard heatmap) versus 29.3% (integral regression) at [email protected]. Backbones are trained with and without the $\sigma=2$ prior of Dive Deeper Into Integral Pose Regression. Each is decoded with a cavity from a shallow skeletal prior built from neighbouring joints. The prediction is that under cavity-informed interval-exact decoding, the unregularized sharp backbone closes most of its gap to the regularized one. If it does not, shrinkage is a training pathology that inference cannot fix, and we will report it as such.
References
- State Space Expectation Propagation: Efficient Inference Schemes for Temporal Gaussian Processes
- Integral Human Pose Regression
- Towards Accurate Multi-person Pose Estimation in the Wild
- Dive Deeper Into Integral Pose Regression
- Localization with Sampling-Argmax
- Heatmap Distribution Matching for Human Pose Estimation
- Fast Bayesian Inference for Non-Conjugate Gaussian Process Regression
- Gaussian process regression with Student-t likelihood
- Approximate Expectation Maximization
- Fast Convergent Algorithms for Expectation Propagation Approximate Bayesian Inference
- ABC-EP: Expectation Propagation for Likelihoodfree Bayesian Computation
- Improving Hyperparameter Learning under Approximate Inference in Gaussian Process Models