RayRoPE: Projective Ray Positional Encoding for Multi-view Attention

Yu Wu, Minsik Jeon, Jen-Hao Rick Chang, Oncel Tuzel, Shubham TulsianiarXiv 2026

TL;DR

RayRoPE is a novel positional encoding mechanism for multi-view vision transformers that represents image patches as 3D ray segments projected into a query camera's local frame. By predicting per-token depth and uncertainty entirely without direct supervision, it achieves geometric adaptiveness and coordinate-system invariance, delivering substantial performance gains across tasks like novel-view synthesis and stereo depth estimation with minimal computational overhead.

What Problem Does This Paper Address?

Vision transformers rely heavily on positional encodings to understand the spatial structure of input tokens. While 2D pixel coordinates work perfectly for single-image tasks, multi-view applications—such as novel-view synthesis or multi-view stereo—complicate things because tokens originate from different cameras with distinct viewpoints.

To effectively reason across multiple images, an ideal multi-view positional encoding should satisfy four key properties:

  1. SE(3) Invariance: Attention scores should depend only on relative camera positions, not an arbitrary global coordinate system.
  2. Uniqueness: The same physical 3D patch observed across different images should map to the same positional encoding.
  3. Geometric Adaptiveness: Encodings should adapt based on the underlying 3D scene structure (e.g., whether two patches see the same 3D point).
  4. Multi-Frequency Similarity: Encodings should support multi-scale reasoning by varying across different frequencies, similar to standard Rotary Positional Encodings (RoPE).

Prior methods fail to satisfy all four criteria simultaneously. For instance, camera-pose-based encodings achieve SE(3) invariance but lack geometric adaptiveness and multi-frequency support, while hybrid approaches break token uniqueness.

Fig. 1: Desiderata for a Multi-View Positional Encoding. We seek the following properties for positional encoding in multi-view attention: (a) The attention output should be invariant to the choice of global coordinate system (i.e., SE(3) invariance). (b) The positional encoding of tokens that correspond to the same patch observed across different images should be the same. (c) The positional encoding can vary with the underlying scene geometry (e.g. yielding higher similarity when patches observe a common 3D point than when they do not). (d) Analogous to common 1D and 2D encodings, aspects of the positional encoding should vary at different frequencies, enabling multi-frequency similarity. RayRoPEsatisfies (a–d) by encoding ray segments projected into each query camera frame.

Methods

The authors introduce RayRoPE (Projective Ray Positional Encoding) to bridge this gap. Instead of treating a patch as a static 2D pixel or a rigid camera matrix, RayRoPE parameterizes each patch as a 3D ray segment defined by its camera center $c$ and a point $p^d$ at depth $d$ along the ray.

Here is how the pipeline works:

  • Query-Frame Projection: To ensure SE(3) invariance, global ray coordinates are projected into the local projective coordinates of the query token's camera frame.
  • Emergent Depth Prediction: Since true scene geometry is rarely known beforehand, RayRoPE adds a single linear layer to each attention block. This layer predicts a per-token depth $d$ directly from the feature representations without any explicit depth supervision.
  • Uncertainty Modeling via Expected RoPE: Approximate depth predictions can introduce high-frequency noise into the positional encodings. To mitigate this, the model also predicts an uncertainty value $\sigma$. The position is treated as a uniform distribution along the ray segment $[d-\sigma, d+\sigma]$, and the authors derive an analytical solution to compute the expected positional encoding, effectively smoothing out unstable high-frequency oscillations when confidence is low.
Overview of the RayRoPE framework showing ray segment parameterization, query-frame projection, and uncertainty modeling.

Datasets

RayRoPE was validated across several diverse datasets and tasks:

  • Novel-View Synthesis (NVS): Evaluated using the LVSM framework on CO3D (complex object categories), Objaverse (synthetic 3D objects), and RealEstate10K (RE10K, indoor/outdoor architectural scenes).
  • Stereo Depth Estimation: Evaluated using the UniMatch framework on RGBD, SUN3D, Scenes11, and zero-shot generalization on ScanNet.
  • 3D Gaussian Splatting (3DGS) & Diffusion: Evaluated using TokenGS and EscherNet frameworks on the DL3DV-10K dataset.

Key Insights and Ideas

  • Emergent Geometry without Supervision: One of the most striking findings is that geometrically plausible depth maps emerge naturally in the deeper layers of the transformer. Because the attention mechanism requires accurate spatial alignment to minimize loss, the network learns to predict depth accurately as an optimal strategy for routing attention.
  • Uncertainty as a Stabilizer: High-frequency channels in rotary encodings are highly sensitive to positional errors. By analytically integrating a uniform distribution over the uncertainty window (Expected RoPE), the model gracefully degrades to lower-frequency, smoother representations when depth estimates are uncertain.
Visualizing how depth errors and predicted uncertainties correlate, alongside the layer-by-layer emergence of clean depth maps.

Key Results

  • Novel-View Synthesis: RayRoPE consistently outperformed state-of-the-art baselines like PRoPE and GTA. Notably, it achieved a 24% relative improvement on LPIPS on the RE10K dataset.
  • Stereo Depth Estimation: Integrating RayRoPE into UniMatch reduced the Absolute Relative Error (Abs Rel) across all tested datasets, including a drop from 0.127 to 0.095 on the unseen ScanNet dataset, showcasing strong zero-shot generalization.
  • Efficiency: Despite computing query-dependent projections and per-token depths, grouping the attention computation by query view keeps the overhead minimal—resulting in only a 4% increase in training time and a 13% increase during inference compared to PRoPE.

Limitations and Future Work

RayRoPE fundamentally relies on the availability of accurate camera poses (posed input images). If camera matrices are noisy or entirely unavailable, the projection mechanics break down. The authors note that modeling uncertainty within the camera matrices themselves, or extending this ray-based formulation to unposed/in-the-wild image collections, represents an important and open direction for future research.

Summary updated

BibTeX
@misc{wu2026rayrope,
  author = {Yu Wu and Minsik Jeon and Jen-Hao Rick Chang and Oncel Tuzel and Shubham Tulsiani},
  title = {{RayRoPE: Projective Ray Positional Encoding for Multi-view Attention}},
  year = {2026},
  eprint = {2601.15275},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2601.15275},
}
Figure