Multimodal alignment: shared anchors and unseen directions
跨模态对齐
Solve orthogonal alignment and expose the ambiguity left by incomplete anchors.
multimodal-alignmentTwo maps can describe the same place with different axes
An image and a sound can refer to the same barking dog without having comparable raw coordinates. Alignment tries to make the relationship usable: paired observations should meet in a shared representation, or their correspondence should otherwise be recoverable. Fusion is the separate question of how to combine available inputs for a task.
CLIP aligns paired images and text with a contrastive objective. ImageBind trains using image-paired modalities and reports alignment between some modality pairs that were not directly paired for training. That empirical result does not prove that sharing an anchor modality always identifies every relevant relationship. Start with CLIP and SVD.
An exactly solvable alignment problem
Let A contain n anchor vectors as rows, and X contain paired observations in another d-dimensional coordinate system. We restrict the mapping to an orthogonal matrix W. This preserves lengths and angles, permits reflections and assumes that no translation or scaling is needed:
This original teaching problem is orthogonal Procrustes, not ImageBind’s neural objective. Expanding the squared Frobenius norm gives:
The first two terms are constant. If the cross-product has singular-value decomposition XᵀA=UΣVᵀ, the trace is at most the sum of singular values, attained by:
For example, eight unit-circle anchors observed through a rotation have an exact inverse-rotation solution. Fit audio and text coordinates separately to the anchors, then compare normalized mapped vectors:
A common orthogonal change of coordinates R leaves these comparisons unchanged:
There is no uniquely meaningful absolute orientation of this shared geometry. More seriously, incomplete anchors can leave relative orientation unresolved. For anchors on the horizontal axis, both the identity I and vertical reflection F fit perfectly:
On unseen vertical vectors, I preserves the target identity while F swaps it. A zero training alignment error has not selected between those possibilities. Full rank removes this particular null-space ambiguity; it does not guarantee that a linear model describes a new population.
Fit, rotate, and remove an anchor direction
Save as multimodal_alignment.py; use Python 3.12 and NumPy 1.26.4. Synthetic audio coordinates rotate by .8 radians and text coordinates by −.5. They are numeric observations, not recordings or words. Each mapping is solved by SVD without gradient descent. A cross-product costs O(nd²), the dense SVD O(d³), and a full n-by-n retrieval comparison O(n²d) with O(n²) score storage.
"""Original orthogonal alignment and an unobserved-direction counterexample."""
import json
import numpy as np
def matrix(x):
x = np.asarray(x, dtype=float)
if x.ndim != 2 or not 1 <= min(x.shape) or max(x.shape) > 256 or not np.isfinite(x).all():
raise ValueError('Expected bounded finite matrix')
return x
def align(x, anchor):
x, anchor = matrix(x), matrix(anchor)
if x.shape != anchor.shape: raise ValueError('Paired shapes must match')
u, s, vt = np.linalg.svd(x.T @ anchor)
return u @ vt, s
def retrieval(x, y):
x, y = matrix(x), matrix(y)
if x.shape != y.shape: raise ValueError('One corresponding target per query')
nx, ny = np.linalg.norm(x, axis=1), np.linalg.norm(y, axis=1)
if np.any(nx == 0) or np.any(ny == 0): raise ValueError('Zero embedding')
scores = (x/nx[:, None]) @ (y/ny[:, None]).T
return float(np.mean(scores.argmax(axis=1) == np.arange(len(x)))), scores
def paired_loss(x, anchor, w):
x, anchor, w = matrix(x), matrix(anchor), matrix(w)
if x.shape != anchor.shape or w.shape != (x.shape[1], x.shape[1]): raise ValueError('Invalid shapes')
return float(np.mean((x @ w-anchor)**2))
def rotation(angle):
c, s = np.cos(angle), np.sin(angle)
return np.array([[c, -s], [s, c]])
def geometry(offset=0):
a = (np.arange(8)+offset)*np.pi/4
return np.stack([np.cos(a), np.sin(a)], axis=1)
def demo():
anchor = geometry(); audio = anchor @ rotation(.8); text = anchor @ rotation(-.5)
wa, _ = align(audio, anchor); wt, _ = align(text, anchor)
held = geometry(.5)
bad, _ = align(audio, np.roll(anchor, 2, axis=0))
# Anchors on the horizontal axis cannot distinguish a vertical reflection.
observed = np.array([[-1., 0], [1., 0]])
identity, flip = np.eye(2), np.diag([1., -1.])
unseen = np.array([[0., 1], [0., -1]])
losses = [paired_loss(observed, observed, w) for w in [identity, flip]]
scores = [retrieval(unseen @ w, unseen)[0] for w in [identity, flip]]
common = rotation(.37)
before = retrieval(audio @ wa, text @ wt)[1]
after = retrieval(audio @ wa @ common, text @ wt @ common)[1]
return dict(before_accuracy=retrieval(audio, text)[0], aligned_accuracy=retrieval(audio @ wa, text @ wt)[0],
heldout_accuracy=retrieval(held @ rotation(.8) @ wa, held @ rotation(-.5) @ wt)[0],
mispaired_accuracy=retrieval(audio @ bad, text @ wt)[0],
paired_mse=paired_loss(audio, anchor, wa), singular_values=align(audio, anchor)[1].tolist(),
rank_deficient_losses=losses, rank_deficient_unseen_accuracy=scores,
common_rotation_error=float(abs(before-after).max()),
anchor=anchor.tolist(), audio=audio.tolist(), aligned=(audio @ wa).tolist(),
scope='Closed-form paired orthogonal fits, not ImageBind training or a universal transfer theorem.')
if __name__ == '__main__': print(json.dumps(demo(), indent=2))
Before alignment, paired retrieval accuracy is zero; afterward it is one on both the eight anchors and eight interleaved held-out angles. The cross-product singular values are [4,4]. This checks the stipulated rotation relationship, not zero-shot recognition. Deliberately rolling the anchor pairing by two places returns accuracy zero despite fitting the wrong correspondence. The rank-deficient example has two zero-loss solutions whose unseen retrieval accuracies are one and zero.
An anchor is useful only for the distinctions it carries
The selected ImageBind method uses symmetric contrastive learning on image-paired observations, with frozen image/text encoders in the described setup. Its result depends on data, representations and optimization. If the anchor modality omits an important distinction, matching it does not automatically recover that distinction elsewhere. No theorem in this example establishes universal emergent alignment.
The fixed released model normalizes modality features and then applies modality-dependent logit scaling to several outputs. Thus “shared space” does not mean every returned vector has unit norm or every pairwise score has identical calibration. The example explicitly normalizes for cosine retrieval and evaluates only paired ranking.
Temporal synchronization, duplicate positives, wrong pairs, differing populations and many-to-one relations need their own checks. Orthogonal fitting cannot correct a nonlinear distortion or invent missing information. A low paired loss and a useful cross-modal task score are related evidence, not interchangeable evidence.
Find the ambiguity
- Derive. If X=AR for orthogonal R and full-rank anchors, what mapping gives zero error? Answer: W=Rᵀ gives XW=ARRᵀ=A. This assumes a pure orthogonal distortion with correct row pairing.
- Diagnose. Why can vertical retrieval fail with zero horizontal-anchor loss? Answer: Horizontal anchors do not distinguish I from the reflection F. Those mappings disagree on unseen vertical points.
- Implement. Can one apply a common rotation to both aligned modalities without changing cosine retrieval? Answer: Yes. Orthogonality preserves dot products and norms. Rotating only one modality generally changes the scores.
- Transfer. Does zero loss on wrongly paired anchors certify semantic alignment? Answer: No. The objective follows the supplied correspondence. The shifted-pair experiment fits a consistent but wrong mapping and retrieves the wrong targets.
Keep pairing, alignment and fusion distinct
CLIP supplies a paired contrastive model; ImageBind studies image-centered links across modalities. Our SVD derivation supplies an exactly solvable counterexample about identifiability, not a replacement for either architecture. Continue to multimodal fusion to ask how aligned information should be combined.
Make a prediction, then check
Do perfect fits on horizontal anchors determine the vertical direction?
Learning objectives
- Derive the orthogonal Procrustes solution.
- Construct an unidentifiable unseen direction.
- Distinguish paired fitting from emergent transfer.
Prerequisites & connections
Explore related knowledge →References
- ImageBind: One Embedding Space To Bind Them All (CVPR2023)
Rohit Girdhar; Alaaeldin El-Nouby; Zhuang Liu; Mannat Singh; Kalyan Vasudev Alwala; Armand Joulin; Ishan Misra · 2023 - Learning Transferable Visual Models From Natural Language Supervision (ICML2021)
Alec Radford; Jong Wook Kim; Chris Hallacy; Aditya Ramesh; Gabriel Goh; Sandhini Agarwal; Girish Sastry; Amanda Askell; Pamela Mishkin; Jack Clark; Gretchen Krueger; Ilya Sutskever · 2021 - facebookresearch/ImageBind: imagebind/models/imagebind_model.py @53680b0
facebookresearch/ImageBind contributors
Version1 · Editorial status: Recorded technical checks completed
View technical check record (AI)
Codex · 2026-09-20 · Single AI author checked ImageBind selected sections3.1-3.3/frozen encoders, reused unchanged CLIP source and checked fixed modality postprocessors. Six paired equations and four explained exercises; original orthogonal Procrustes derivation, trace optimum, rotations/reflections, pairing errors and rank-deficient unseen directions. No ImageBind training or universal emergent-transfer theorem.
- Single AI author checked ImageBind selected sections3.1-3.3/frozen encoders, reused unchanged CLIP source and checked fixed modality postprocessors. Six paired equations and four explained exercises; original orthogonal Procrustes derivation, trace optimum, rotations/reflections, pairing errors and rank-deficient unseen directions. No ImageBind training or universal emergent-transfer theorem.
- Four computed SVG variants per topic. Fifteen numeric/geometry tests and36 responsive cases passed; twelve final Chinese-mobile/English-desktop screenshots actually inspected. Initial label polish and English mobile-title clipping correction preserved. Full article acceptance recorded separately.
Source locations checked:
- ImageBind: One Embedding Space To Bind Them All (CVPR2023) · Read sections3.1-3.3 and selected frozen-encoder setup in4; PDF3 viewed. Emergent alignment is an empirical report, not a universal theorem.
- Learning Transferable Visual Models From Natural Language Supervision (ICML2021) · Read selected2.2-2.3, Figure3 and candidate-classification description; PDF page3 viewed. No original training or natural-image benchmark reproduction.
- facebookresearch/ImageBind: imagebind/models/imagebind_model.py @53680b0 · Read418-470: modality postprocessing and call order. Fixed LICENSE says CC BY-NC-SA4.0; heading/opening only. No code/weights reused.
Related topics