Route-Cross Attention: Following the Lane Graph Instead of the Ruler in Multi-Agent Motion Forecasting

Forecasting what nearby cars will do requires each car's representation to "see" the right parts of the scene. Current vector-based forecasters choose what each agent attends to by straight-line distance, keeping, for example, the 128 map elements nearest to a trajectory hypothesis. Roads do not work that way. A car two meters away across a concrete median is irrelevant. A car 60 meters upstream on a merging ramp is the one that matters. We propose to make attention follow the road graph: the directed network of lanes with predecessor, successor and neighbor links that maps such as Argoverse and Waymo already provide.

The design borrows from criss-cross attention in vision. There, two cheap passes, one along rows and one along columns, give every pixel a view of the whole image. Our version has one pass that runs along each agent's reachable lanes and a second that runs across the lanes that merge into or conflict with them. After both passes, any two agents that could meet at a shared conflict point within the forecast horizon have exchanged information. Agents that are close in space but cannot reach each other on the road never get mixed together. The claim we test is narrow. In scenes where Euclidean neighborhoods and lane-graph reachability disagree, routing attention by reachability improves joint forecasts and reduces predicted collisions between agents. It should do so at lower cost than dense attention, and better than dense attention with a learned graph-distance bias.

Core Claim and How It Differs From Existing Work

Three ingredients exist separately in the file, and none combines them.

The first is the Euclidean receptive-field heuristic and its alternatives. MTR-A uses a transformer encoder-decoder that gathers the 128 nearest polylines per trajectory query. VectorNet applies fully connected attention over polyline tokens with no road-topology prior. MultiPath++ pools the whole scene into a gated summary vector. These motivate the gap: all three either use straight-line distance or ignore structure.

The second is factorized global reach. CCNet gets full-image context from two passes along rows and columns, with 11x less memory than a non-local block. It is confined to pixel grids, and it supplies the "two orthogonal sparse passes" idea we transplant.

The third is topology-shaped attention. Topoformer masks attention heads with a DAG's skeleton, its reachability closure, and its pairs of incomparable nodes. Graphormer adds learnable shortest-path-distance biases to attention scores. These supply the method. Our "along" pass is Topoformer's reachability view applied to a lane graph truncated at the forecast horizon. Our "across" pass plays the role of its parallel-branch view, rewritten for lanes that share a merge or crossing point.

The closest work on interaction structure is JFP. It builds a graph over agents whose candidate trajectories overlap in space and resolves conflicts with belief propagation in the decoder, halving overlap rate. Our proposal differs in three ways. The interaction graph is defined by road topology rather than by bounding-box interference. It acts in the encoder. It is ordinary differentiable masked attention.

Mechanism

Let $\ell(i)$ be the lane an agent or polyline token $i$ occupies. Let $R_H(i)$ be the set of lanes reachable from $\ell(i)$ along successor links within a path length set by the horizon $H$ and the agent's speed. Let $C(i)$ be the set of lanes that share a merge, split or crossing point with some lane in $R_H(i)$, together with their own predecessors within the same budget. The two passes use the same weights, as in recurrent criss-cross attention:

$$ \text{pass 1: } j \in \mathcal{A}(i)=\{j:\ell(j)\in R_H(i)\cup R_H^{-1}(i)\}, \qquad \text{pass 2: } j \in \mathcal{X}(i)=\{j:\ell(j)\in C(i)\}. $$

Here $R_H^{-1}(i)$ is the set of lanes from which $\ell(i)$ is reachable, so that followers are included.

Within each pass, scores receive a Graphormer-style learned bias indexed by bucketed geodesic distance along the lane graph. These sets come from a truncated graph search per token, which costs roughly the number of lane edges inside the horizon. This avoids the cubic all-pairs shortest-path precomputation that Graphormer identifies as a bottleneck. It also means topology can be recomputed each frame as agents change lanes.

Agents not on a lane, such as pedestrians or cars in parking lots, fall back to a small Euclidean neighborhood. We report how often this fallback fires.

Research Program

We will build Route-Cross Attention as a drop-in replacement for the scene encoder and the map-collection step of an MTR-style forecaster. Decoder, losses and training schedule are held fixed, so that only the routing changes.

The central analysis is a per-scene disagreement score: the Jaccard distance between each agent's Euclidean top-K token set and its topological set $\mathcal{A}\cup\mathcal{X}$. We predict that gains over Euclidean routing grow with disagreement and are near zero when the two sets coincide. If gains are spread uniformly regardless of disagreement, the mechanism is not doing what we claim, and a sparsity or regularization effect is the more likely explanation.

We will also mine a "topological trap" subset of the Waymo interactive split. It consists of divided highways, overpasses, and long merge lanes where the relevant interactor lies beyond the Euclidean top-K. We will report results on it separately.

Baselines

The naive reference point is a marginal forecaster with Euclidean nearest-K map collection and no agent-agent interaction beyond that neighborhood. This is the MTR-style encoder with interaction attention removed. It tells us how much any interaction routing buys.

The strongest existing method is the MTR-A recipe of dynamic Euclidean map collection with intention and searching queries. Its reported number is Soft mAP 0.4594 and Miss Rate 0.1160 on the 2022 Waymo leaderboard, from MTR-A. That figure is a seven-model ensemble on the test server, and no reported single-model validation result was found on Lacuna for MTR-A. We will therefore retrain a single-model reimplementation and compare against it, using the same data, epochs, hyperparameter search budget and parameter count. Beating it means higher Soft mAP and lower miss rate on the validation interactive split across three seeds, and a clearly larger margin on the topological-trap subset.

MultiPath++ is a second reference. It reports 0.409 mAP and 0.556m minADE on the leaderboard and is the global-summary alternative. For joint consistency, the reference is JFP, which reports overlap rate falling from 0.064 (MultiPath++) to 0.030 on the Waymo interactive validation set. We will report overlap rate for every model. Matching JFP's overlap reduction without a belief-propagation decoder would count as a strong result. Stacking JFP's decoder on our encoder tests whether the two effects add.

Ablations isolate the key ingredient. We compare the along-pass alone, the across-pass alone, and both passes. A random sparse mask with the same per-token budget tests whether the gain is just sparsity. The union of the Euclidean and topological sets tests whether topology adds information or merely replaces it. Finally, we run both passes with and without the geodesic bias.

Why not just…?

Why not just put a Graphormer shortest-path bias on dense attention? This is the real threat. With a few hundred tokens, dense attention is affordable, and a learned lane-graph distance bias could learn to down-weight unreachable tokens on its own. Graphormer shows that such biases are what make transformers competitive on graphs. Nothing in the file shows that hard masks beat soft biases. We will run dense attention with a lane-geodesic bias, including an "unreachable" bucket, as a full competitor. If it matches us on the trap subset, we will report that the contribution reduces to efficiency (memory and latency at large token counts) and reframe the work accordingly.

Why not just raise K in Euclidean collection? A larger radius eventually includes the distant merge-lane car. It also includes more across-the-median distractors, and cost grows with K. We will sweep K and plot accuracy against attended-token count for both routings. The claim holds only if topological routing dominates that curve, rather than at a single budget.

Why not just add lane-ID or connectivity features to the tokens and let attention sort it out? This is cheaper to implement. It is close in spirit to VectorNet's unconstrained attention, which leaves topology to be learned from data. We include it as a baseline at an equal parameter count. The disagreement-score analysis shows whether learned features close the gap in high-disagreement scenes.

Why not just fix consistency in the decoder as JFP does? JFP removes collisions between agents' candidate trajectories, but it cannot recover an interactor the encoder never saw. Our trap-subset results with and without a JFP-style decoder separate the two failure modes.

Proposed Experiments

The primary benchmark is the Waymo Open Motion Dataset interactive split. We report Soft mAP, miss rate, minADE/minFDE and overlap rate, overall and binned by disagreement score.

The secondary benchmark is Argoverse. Its lane maps provide explicit predecessor and successor links, and VectorNet reports 4.01m DE@3s there as a reference point. Efficiency is measured as peak memory and latency as scene token count scales, against dense attention.

There are two decisive checks. The first is a positive slope of gain against disagreement score, with near-zero gain at low disagreement. The second is that topological routing beats the dense geodesic-bias baseline on the trap subset at equal compute. If the first check fails, the idea is wrong. If only the second fails, the result is an efficiency method rather than an accuracy method.