Temporally Grounding Instructional Diagrams in Unconstrained Videos

Jiahao Zhang, Frederic Z. Zhang, Cristian Rodriguez, Yizhak Ben-Shabat, Anoop Cherian, Stephen Gould

TL;DR

This paper introduces a novel method for "temporally grounding" a sequence of instructional diagrams (like those in an IKEA manual) within unconstrained YouTube videos. By using "composite queries" that combine visual diagram features with learnable positional embeddings, the model learns to localize all steps simultaneously, respecting the temporal order and reducing overlapping predictions.

What Problem Does This Paper Address?

Imagine trying to find the exact moment in a 20-minute YouTube video where a creator performs "Step 12" of a furniture assembly. This task, known as Temporal Sentence Grounding in Videos (TSGV), is usually done with text. However, instructional manuals often rely on diagrams, which lack textual descriptions.

Existing methods typically ground one query at a time. This is problematic for instructional sequences because it ignores the inherent structure: steps usually happen in a specific order and don't overlap much. When models look at steps in isolation, they often produce "messy" results where Step 5 is predicted to happen before Step 2, or multiple steps are predicted to occur at the exact same time. Furthermore, real-world videos are "unconstrained"—creators might skip steps, repeat them, or perform two tasks simultaneously, making strict temporal constraints too rigid.

Methods

The authors propose a DETR-based (Detection Transformer) approach that shifts from localizing one step at a time to grounding the entire sequence simultaneously.

Schematic of the overall pipeline showing feature extraction and the construction of composite queries.

1. Composite Queries

The core innovation is the Composite Query. Instead of using generic learnable queries, the model creates a set of queries by taking the Cartesian product of:

  • Content Priors: Visual features from each diagram ($M$ diagrams).
  • Positional Priors: A small set of learnable positional embeddings ($K$ queries).

This results in $M \times K$ composite queries. Because each query is already "tagged" with a specific diagram's features, the model doesn't need a separate classification step to figure out which prediction belongs to which diagram.

2. Decoder-Only Architecture

Drawing on recent research suggesting that transformers' encoders can cause "temporal collapse" (where attention focuses too narrowly), the authors remove the encoder entirely. Diagram features act as content priors for the queries, while video features serve as the "keys" in the decoder.

3. Masked Self-Attention

To manage the interactions between these $M \times K$ queries, the authors designed specific attention masks. The goal is to allow queries for the same diagram to compete (suppressing overlaps) while preventing noise from unrelated diagrams. Their "Type D" mask was found to be the most effective.

4. Jointly Guided Cross-Attention

Instead of simply adding content and position features (which can create noisy cross-terms), the model concatenates them. This ensures the cross-attention mechanism is explicitly guided by both what the step looks like and where it is likely to occur in the sequence.

Comparison of the proposed architecture with existing models like Moment-DETR and LVTR.

Datasets

  • IKEA Assembly in the Wild (IAW): The primary benchmark, containing 1,007 videos and corresponding instructional diagrams. It is particularly challenging because the number of steps varies widely (from 2 to 79) and videos are unconstrained.
  • YouCook2: A standard benchmark for grounding natural language sentences in cooking videos, used here to demonstrate the model's versatility across different query types (text vs. images).
  • ActivityNet-Captions: Used for additional evaluation against dense event grounding methods.

Key Insights and Ideas

  • Joint Localization is Key: Grounding steps as a sequence allows the model to use the "temporal context" of other steps to refine its predictions.
  • Self-Attention as NMS: In a multi-query setup, self-attention naturally acts as a form of Non-Maximum Suppression (NMS). Queries "fight" for the best timespan, which helps eliminate redundant, overlapping predictions.
  • Positional Guidance Corrects Visual Noise: YouTube videos are noisy. A visual match might occur in the wrong place (e.g., a creator showing a part before actually using it). The positional encodings act as a "sanity check," steering the model toward the correct temporal window based on the step's index in the manual.

Key Results

The model significantly outperformed existing state-of-the-art methods:

  • On IAW: When integrated with the EaTR backbone, the method achieved a 42.02% R@1 (IoU=0.3), a substantial jump over the baseline EaTR (38.48%) and Moment-DETR (34.00%).
  • On YouCook2: It achieved a 35.32 mIoU, outperforming specialized models like DORi and LocFormer, despite not using additional object-relationship features.
  • Qualitative Success: Visualizations show that the model effectively reduces timespan overlaps and maintains a higher correlation with the ground-truth temporal order compared to single-query methods.
Figure 1. An illustration of the temporal instructional diagram grounding task between a YouTube video (top) xPNkHAii3fU and an Ikea furniture manual (bottom) 00352894. This task aims to predict the start and end timestamps for all step diagrams simultaneously.

Limitations and Future Work

  • Sequence Entry Points: The model struggles if a video starts in the middle of a manual (e.g., a video that only covers steps 8 through 12). The current positional encoding assumes a standard sequence start.
  • Modality Gaps: The current approach relies purely on visual features. The authors suggest that incorporating audio cues (like a narrator saying "Now, take the long screw...") could further improve accuracy.
  • Domain Expansion: While furniture and cooking are the focus here, the authors see potential in applying this to medical procedures or complex industrial maintenance tasks.

Summary updated

BibTeX
@inproceedings{zhang2025temporally,
  author = {Jiahao Zhang and Frederic Z. Zhang and Cristian Rodriguez and Yizhak Ben-Shabat and Anoop Cherian and Stephen Gould},
  title = {{Temporally Grounding Instructional Diagrams in Unconstrained Videos}},
  booktitle = {IEEE/CVF Winter Conference on Applications of Computer Vision},
  year = {2025},
  doi = {10.1109/wacv61041.2025.00786},
}
Figure