FastJAM: a Fast Joint Alignment Model for Images
Omri Hirsch, Ron Shapira Weber, Shira Ifergane, Oren Freifeld
TL;DR
FastJAM addresses the need for fast, scalable joint alignment (JA) of image sets by replacing dense feature maps with a sparse keypoint (KP) graph and a lightweight Graph Neural Network. The method constructs a graph from pairwise KP matches (intra- and inter-image edges), applies a 5-layer GraphSAGE to propagate alignment cues, pools per-image embeddings, and predicts homographies via a Lie-algebraic, inverse-compositional objective. The core contributions include the first inverse-compositional JA loss over sparse KP representations, object-centric KP extraction with DP-Means clustering to reduce redundancy, and a pipeline that achieves under $50$ seconds on benchmarks while matching or exceeding prior JA methods in alignment quality. Empirically, FastJAM outperforms contemporary JA approaches on SPair-71k and CUB-200 in accuracy and dramatically reduces computation time, highlighting the practicality of sparse graphs for large-scale image alignment in real-world workflows.
Abstract
Joint Alignment (JA) of images aims to align a collection of images into a unified coordinate frame, such that semantically-similar features appear at corresponding spatial locations. Most existing approaches often require long training times, large-capacity models, and extensive hyperparameter tuning. We introduce FastJAM, a rapid, graph-based method that drastically reduces the computational complexity of joint alignment tasks. FastJAM leverages pairwise matches computed by an off-the-shelf image matcher, together with a rapid nonparametric clustering, to construct a graph representing intra- and inter-image keypoint relations. A graph neural network propagates and aggregates these correspondences, efficiently predicting per-image homography parameters via image-level pooling. Utilizing an inverse-compositional loss, that eliminates the need for a regularization term over the predicted transformations (and thus also obviates the hyperparameter tuning associated with such terms), FastJAM performs image JA quickly and effectively. Experimental results on several benchmarks demonstrate that FastJAM achieves results better than existing modern JA methods in terms of alignment quality, while reducing computation time from hours or minutes to mere seconds. Our code is available at our project webpage, https://bgu-cs-vil.github.io/FastJAM/
