Aligning Step-by-Step Instructional Diagrams to Video Demonstrations

Jiahao Zhang, Anoop Cherian, Yanbin Liu, Yizhak Ben-Shabat, Cristian Rodriguez, Stephen Gould

TL;DR

This paper introduces the novel task of aligning abstract, step-by-step assembly diagrams (like IKEA manuals) with real-world, "in-the-wild" instructional videos. To tackle this, the authors present IAW (IKEA Assembly in the Wild), a massive new dataset, alongside a specialized contrastive learning framework that leverages temporal progress priors and task-specific losses to outperform standard multimodal models like CLIP.

What Problem Does This Paper Address?

While multimodal alignment has made massive strides in linking text or audio to video, aligning abstract line drawings to real-world video sequences remains a significant challenge.

When you watch an amateur YouTube video of someone assembling a flat-pack bookshelf, the video is messy: it contains varying camera angles, lighting changes, irrelevant commentary, and mistakes. On the other side, the instruction manual consists of highly stylized, text-free, black-and-white diagrams where successive steps often look nearly identical (e.g., adding a single screw). Standard text-to-video or image-to-video models fail here because they cannot easily bridge the massive domain gap between abstract sketches and complex physical environments, nor can they easily distinguish the subtle, fine-grained differences between sequential assembly steps.

Methods

The authors propose a supervised contrastive learning framework designed to map both video clips and instructional diagrams into a shared embedding space.

Figure 2. Schematic of our overall architecture. During training we extract features from each input video clip and set of instructional dia- grams, respectively, using pre-trained encoders. We concatenate these with sinusoidal progress rate features (SPRF) introduced in Sec. 3.1 and project into the same Dℓdimensionality space. The matched video clip and instructional diagram feature pairs are used for Video- Diagram Contrastive Loss, the video clip feature and M instructional diagram features are fed into Video-Manual Contrastive Loss, and M instructional diagram features themselves are used in Intra-Manual Contrastive Loss introduced in Sec. 3.2. During inference all video features from N sequential video clips, and all M instructional diagram features from the corresponding manual are computed. We then form a similarity matrix and apply optimal transport (OT) introduced in Sec. 3.3 to produce the final alignment probabilities.

The core architecture relies on several clever domain-specific modifications:

  1. Sinusoidal Progress Rate Feature (SPRF): Since assembly follows a sequential order, the authors inject a temporal prior. They calculate the relative progress through a video and a manual (e.g., step 5 out of 10 is 50% progress) and map this progress onto a half-circle using sine and cosine functions. This ensures that temporal proximity naturally aligns with cosine similarity in the embedding space.
  2. Three Tailored Contrastive Losses: Instead of relying solely on a standard InfoNCE loss, the model optimizes three distinct objectives:
  3. Video-Diagram Contrastive Loss: Uses Jensen-Shannon divergence to gracefully handle many-to-one mappings (where multiple video segments correspond to a single manual step).
  4. Video-Manual Contrastive Loss: Exploits the prior knowledge that a video clip only needs to match steps within its own manual, drastically reducing the false-positive space during training.
  5. Intra-Manual Contrastive Loss: Explicitly pushes diagrams from the same manual apart from one another, forcing the model to learn fine-grained visual discrimination between similar-looking steps.
Figure 3. Visualization of our three losses described in Sec. 3.2. The intent is depicted in the first row and the batch formation in the second row. Loss (a) tries to pair video and image up across the entire dataset. Loss (b) only matches video clips and images corresponding to the same manual. And loss (c) push images from the same manual apart from each other for better feature discrimination.

During inference, the model generates a similarity matrix across the entire video and manual. It then applies Optimal Transport (OT) or Dynamic Time Warping (DTW) to globally align the sequences.

Datasets

The authors introduce the IKEA Assembly in the Wild (IAW) dataset, a large-scale benchmark containing:

  • 1,005 raw videos totaling 183 hours of footage scraped from YouTube.
  • 8,263 illustrative diagrams extracted from 420 unique furniture types across 14 categories (beds, chairs, sofas, etc.).
  • 15,649 precisely annotated actions mapping video segments directly to manual steps, crowdsourced via Amazon Mechanical Turk.

Key Insights and Ideas

  • The Power of the Manual Prior: The single biggest performance jump came from the Video-Manual Contrastive Loss. Restricting the contrastive learning pool to the steps of the specific manual being assembled—rather than contrasting against every manual in the dataset—drastically simplifies the optimization landscape.
  • Optimal Transport Beats Time Warping: Intuitively, one might think Dynamic Time Warping (DTW) would perform best because it strictly enforces chronological order. However, the authors found that Optimal Transport (OT) yielded better results. This is because real-world builders often perform steps out of order, or the model encounters strong false matches that DTW's rigid constraints propagate downstream.
Figure 5. An example of post processing with DTW and OT with furniture 30341149 and video dzLNgz861Hk.
  • Page-Level Regularization: Training the model to match video clips to entire manual pages (in addition to individual cropped steps) acted as an effective regularizer, improving the model's performance even when it was evaluated purely on step-level retrieval.

Key Results

The proposed framework was evaluated on two primary tasks: video-to-diagram retrieval and sequence alignment.

  • Retrieval Superiority: The proposed method achieved a 28.62% Top-1 Accuracy for video-to-diagram step retrieval, outperforming a competitive CLIP baseline (19.61%) by 9.68%.
  • Sequence Alignment Boost: When performing full video-to-manual alignment using Optimal Transport post-processing, the framework achieved 31.61% accuracy on steps and 36.71% accuracy on pages, marking a 12% improvement over baseline alternatives.

Limitations and Future Work

Despite its strong performance, the method has a few limitations:

  • Fully Supervised: The framework relies heavily on expensive, human-annotated ground-truth alignments between videos and diagrams. Moving toward weakly supervised or unsupervised alignment is a key next step.
  • Single-Modal Video Processing: The model currently ignores audio and speech. Integrating video narrations (e.g., the presenter saying, "Now, take the long wooden dowel...") could significantly resolve visual ambiguities.

The authors envision this work paving the way for AR applications that can automatically monitor and guide a human through a DIY project, or help robots learn to perform complex physical tasks directly from human manuals.

Summary updated

Abstract

Multimodal alignment facilitates the retrieval of instances from one modality when queried using another. In this paper, we consider a novel setting where such an alignment is between (i) instruction steps that are depicted as assembly diagrams (commonly seen in Ikea assembly manuals) and (ii) video segments from in-the-wild videos; these videos comprising an enactment of the assembly actions in the real world. To learn this alignment, we introduce a novel supervised contrastive learning method that learns to align videos with the subtle details in the assembly diagrams, guided by a set of novel losses. To study this problem and demonstrate the effectiveness of our method, we introduce a novel dataset: IAW for Ikea assembly in the wild consisting of 183 hours of videos from diverse furniture assembly collections and nearly 8,300 illustrations from their associated instruction manuals and annotated for their ground truth alignments. We define two tasks on this dataset: First, nearest neighbor retrieval between video segments and illustrations, and, second, alignment of instruction steps and the segments for each video. Extensive experiments on IAW demonstrate superior performances of our approach against alternatives.
BibTeX
@inproceedings{zhang2023aligning,
  author = {Jiahao Zhang and Anoop Cherian and Yanbin Liu and Yizhak Ben-Shabat and Cristian Rodriguez and Stephen Gould},
  title = {{Aligning Step-by-Step Instructional Diagrams to Video Demonstrations}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2023},
}
Figure