Parts of Speech–Grounded Subspaces in Vision-Language Models
Authors: James Oldfield
Christos Tzelepis
Yannis Panagakis
Mihalis Nicolaou
Ioannis Patras
Venue: NeurIPS 2023 poster (2023)
Keywords: generative models
text-to-image
vision-language models
interpretability
TL;DR: We learn geometry-aware subspaces in vision-language models that separate representations of the content of an image/text from its appearance

Abstract: Latent image representations arising from vision-language models have proved immensely useful for a variety of downstream tasks. However, their utility is limited by their entanglement with respect to different visual attributes. For instance, recent work has shown that CLIP image representations are often biased toward specific visual properties (such as objects or actions) in an unpredictable manner. In this paper, we propose to separate representations of the different visual modalities in CLIP’s joint vision-language space by leveraging the association between parts of speech and specific visual modes of variation (e.g. nouns relate to objects, adjectives describe appearance). This is achieved by formulating an appropriate component analysis model that learns subspaces capturing variability corresponding to a specific part of speech, while jointly minimising variability to the rest. Such a subspace yields disentangled representations of the different visual properties of an image or text in closed form while respecting the underlying geometry of the manifold on which the representations lie. What’s more, we show the proposed model additionally facilitates learning subspaces corresponding to specific visual appearances (e.g. artists’ painting styles), which enables the selective removal of entire visual themes from CLIP-based text-to-image synthesis. We validate the model both qualitatively, by visualising the subspace projections with a text-to-image model and by preventing the imitation of artists’ styles, and quantitatively, through class invariance metrics and improvements to baseline zero-shot classification.

Parts of Speech-Grounded Subspaces in Vision-Language Models
James Oldfield Christos Tzelepis' Yannis Panagakis 2,3
Mihalis A. Nicolaou
Toannis Patras'
Queenn Mary University of London National and Kapodistrian University of Athens
pechimedes/Athena RC
"The Cyprus Institute
Abstract
Latent image representations arising from vision-language models have proved immensely useful for a variety of downstream tasks. However, their utility is lim- ited by their entanglement with respect to different visual attributes. For instance, recent work has shown that CLIP image representations specific visual properties (such as objects or actions) an unpredictable manner. In this paper, ities in CLIP's joint vision-language space by leveraging the association between parts of speech and specific visual modes of variation (e.g. nouns relate objects, adjectives describe appearance). This is achieved by formulating an appropriate component analysis model that learns subspaces capturing variability correspond- ing to specific part of speech, while jointly minimising variability to the rest. Such subspace yields disentangled representations of the different visual properties of an image or text in closed form while respecting the underlying geometry of the manifold on which the representations lie. What's more, we show the proposed model additionally facilitates learning subspaces corresponding to specific visual appearances (e-g. artists' painting styles), which enables the selective removal of en- tire visual themes from CI.IP-based text-to-image synthesis. We validate the model both qualitatively, by visualising the subspace projections with text-to-image model and by preventing the imitation of artists' styles, and quantitatively, through class invariance metrics and improvements to baseline zero-shot classification.
often biased towards
propose separate representations of the different visual modal-
Introduction
Many recent advances machine learning have been driven by vision-language (VL) models' ability to learn powerful, generalisable image representations from natural language supervision [1, 3, The image features from VL models well-capture representations of many visual attributes as evidenced by the broad applicability they have found for in downstream tasks. The image text encoders of CLIP in particular [1] have been used for controllable image synthesis [4, 5, 6), image captioning [7, 8], and multiple other discriminative tasks [9, 10, 11]. However, modelling the many different visual modalities in single vector representation is not without its drawbacks-recen work shows that CLIP's visual representations are often entangled. For example, Goh al. [12] find that specific neurons fire in response to both images containing a visual concept and images of text relating to the same concept. This leaves CLIP open vulnerabilities in the form of "Typographic attacks' -writing another class name as text on the image can often cause CLIP to predict this class with a higher probability than that of the original image's true category. Other recent works show that CLIP's visual representations encode task task-specific attributes (such as of the object or action depicted in an image) in
"Corresponinng author: j. j.a. oldd aldfield@quul.ee ac. uk
37th Conference on Neural Information Processing Systems (NcurIPS 2023).

---

Prompt: "Vincent Van Gogh M
CLIP
image-vord similarity
image
original
goldfish
golden
swimming
PROJECTION
hown
Noun goldfish gol den swimming
Adj. goldfish golden swimming
Verb goldfish golden swimming
PoS subspaces
(a) Image-word similarity with both CLIPP's embedding and after projecting it onto the PoS subspaces.
(h) Text-to-image visualisation of the subspace disen- tanglement of phrases with multiple visual associations.
Figure 1: CLIP represents multiple visual modes of variation in an embedding (e.g. the 'object' and its aappearance), The learnt PoS subspaces more reliably separate the constituent visual components.
an unpredictable manner, and often the embedding is biased in the prominence with which encodes different modalities [13]. We show in Figure la motivating example of this problem identified by Menon al. [13]-the 'goldfish' noun embedding dominates the image's ' representation despite there being multiple additional labels which accurately describe important information about the image's s contents. As a visual example, we find that CLIP encodings of text prompts containing 'visually polysemous' [14] phrases of artists' names lead CLIP-based text-to-image models [15] to synthesize an unpredictable combination of both images of the artists and of artworks in their signature styles (as shown in Figure lb). Multiple visual associations of the text prompt, including both the appearance of the artist themselves and the style of their artwork, are entangled in the same CLIP embedding. For VL representations make for useful image features, it's vital that the particular modalities of interest are indeed well-repree rell-represented in the embedding. One popular means to this end is fine- peenttnnng the representations for specific downstream tasks [9]. However, this not only requires additional computation but makes the restrictive assumption of the existence of labelled data for each task.
In this paper, we address the problem of better disentangling the modes of visual variation in CLIP's shared vision-language space. In particular, we ask the question: do there exist subspaces in CLIP's joint VL space that capture the representations of the 'content" of an image text, that are invariant to its 'appearance"? To take the first steps towards achieving this we leverage the association between parts of speech in natural language and specific modes of visual variation: isolates representations of the 'object' of an image or text prompt (c.g. an animal in an image, or the noun described in a sentence), and the adjective space its appearance (e.g. whether an object is shiny, or a scene is snowy). This image-text semantic similarity is instilled in the representations through CLIP's contrastive learning training objective, through which it is encouraged to learn image encodings that have large cosine similarity in the shared vision- lision-language space with text encodings of captions describing its visual content. We show how by using example words in the parts of speech categories in the WordNet [16] database, one can extract representations of both image and text embeddings that better isolate the individual modes of visual variation. This is in contrast to the method of VI. model 'prompting' [17, 18, 13], which often steers the embeddings of either only the text or image modality. We take inspiration from the related line of work that finds so-called 'interpretable directions' in latent space [19, 20, 21, 22, 23] that capture high-level semantic attributes- however, we learn subspaces that capture variation uniquely present amongst representations of words of particular parts of speech. We achieve this by formulating an appropriate objective function which we show can be manipulated into well-known trace maximisation problem with a fast solution given in closed form. Since the CLIP representations live on the hypersphere [24], we further propose manifold generalisation of the subspaces [25, 26] (illustrated in Figure 2) that share the property of capturing the variance of only the desired visual attributes, yet better respect the manifold on which the data lie. Concretely, we compute the proposed component analysis the tangent space to the sphere's 's intrinsic mean, which can be seen local approximation of the manifold [27].
learnt noun subspace

---

The method's is ability to disentangle visual modes of variation is measured both qualitatively and quantitatively. Using popular CLIP-based text-to-image model we demonstrate visually how the learnt PoS subspaces can better separate the content from the style associated with text prompt. We show, for example, how simply projecting onto the orthogonal complements of the noun and adjective subspaces respectively can more reliably produce images of either the artists' work, or of the artists themselves, as shown in rows 2 and 3 of Figure 1b. We find removing a CLIP representations' adjective space component to be remarkably effective for preventing the visual imitation of artists' styles in this new class CLIP-based text-lo-image models [15], addressing societal concerns the technology. Further, we show our objective additionally facilitates learning subspaces corresponding to more specific visual appearances (e.g. 'gory"). Projections onto the orthogonal complements of such subspaces consequently remove entire visual themes from text-to-image models, whilst preserving existing concepts through the PoS guidance.
Finally, we validate the subspaces' ability to isolate visual modes of variation quantitatively through a measure of class invariance (comparing to two existing baselines), and by showing how the baseline zero-shot classification protocol in the learnt subspaces leads to higher accuracies on the ViT-B-33 CLIP model on 14/15 datasets considered. Our contributions can be summarised as follows:
We present a method for learning geometry-awe subspaces in CLIP's shared vision- language space that disentangle representations of the content in an image or text prompt from the way it looks, using parts of speech as supervision. To the best of our knowledge, we are the first to use the semantic relationship between parts of speech and specific visual modes of variation to disentangle CL.IP's shared vision-language space.
We formulate and solve an appropriate trace maximisation problem that admits fast closed-form solution respecting the manifold on which the data lie.
We validate our method's success at disentangling the visual modes of variation both quantitatively and qualitatively: by visually separating text prompt's 'content' from its "appearance' with text-to-image models for the former and through improved zero-shot classification in the submanifolds for the latter.
We show the model's ability to further learn subspaces of more specific appearance-based variation (e.g. artists' styles), providing a way of erasing entire visual themes from CLIIP- based text-to-image models.
2 Method
We first recall the basics of CLIP. We then motivate and introduce our objective function for learning parts of speech-specific linear subspaces in Section 2. and detail its closed-form solution in Section 2. Finally, in Section 2.2 we show how to learn subspaces of the tangent space to the CLIP VL hypersphere's 's intrinsic mean, which better respects the geometry of the manifold on which the CLIP representations lie.
CLIP preliminaries Pre-trained image and text encoders map images and text respectively to latent representations 2,, 27 E R2 in a shared vision-language (VL) space [1]. For test-time zero-shot classification, candidate text prompts are first encoded with the text encoder. Then, the cosine similarity between an encoded image representation of interest and the text candidates is computed with S(zr, 21) = z z, / /[|zr|l ||z
(), after which the softmax function is applied to determine the most likely text label for the image. We now address the task of extracting representations of solely the target modes of variation in the section that follows.
2.1 Objective
We seek a lower-dimensional subspace on which to project either a text or image CLIP representation E 1Rd to predictably isolate the desired visual mode of variation. We achieve this through natural language supervision in the form of words from the different parts of speech. Let the elements of a set C index into the relevant word class of interest (i.e. C (N, A, V. R) for nouns, adjectives, verbs, and adverbs respectively), and X; E Rdxn, Vi E C contain in their columns the CLIP encodings of n words belonging to word class i [16]. Then, for a word class C of interest, we seek k k-dimensional subspace of dd spanned by the columns of learnt W E dddk in which the CLIP
3

---

RA
Bg (og
Tusa-1
T Tud-1
Tuga-1
(t) (e)
Exy,, ( (WWWgaagaaa)
PCA
2 1/2
Map Tangent intrinatic
Project onto desired sulssaace
(3) Map back to VL sphara
Figure 2: Our proposed method, shown on toy data, for learning 'geodesic submanifolds' [25] that capture the variance of visual attributes uniquely associated with specific parts of speech. After mapping to the tangent space (1), a linear subspace of the tangent space is learnt that captures the variation in only the target class (leading eigenvectors of C₁). Test samples can then be projected onto this subspace (2), and mapped back (3) the VI. sphere.
representations of the words in the class of interest have large norm and the remaining categories representations in \ {i} are close to the zero vector. Intuitively, a hyperplane with this property models factors of variation that are uniquely present in representations of text that belong particular part of speech. We quantify this by formulating the following objective function:
{
W, arg max
W), X
ΣxI X, 1,1
(1)
W.W.=L.
jEC(()
where E [0, 1] is a hyperparameter that controls the importance of killing the variation in the non-target categories relative to preserving the variation in the target class.
2.1.1 Closed-form solution
Imposing column orthonormality on W, not only ensures its columns span a full k-dimensional subspace, but also allows Equation (1) to be solved in closed form. Concretely, we first manipulate the objective as follows
(1 W x
Σ w/// 1
jECNA
(1 - A)tr (WW X2) (W.X.)) Σ Aur ((W, X,) (W.X,))
(2)
jECYF
= -1-X)
ΣAXxX]Iw.))
(3)
SECU(1)
=tr(WTC.W.)
(4)
where C; = ((1 X)X Ejec XX,X,) Having now reformulated our original objective in Equation (1) as (constrained) trace maximisation problem, its solution W, given in closed form² as the leading eigenvectors of C.
For case of presentation, we have assumed the number of data points in each class to be equal. One account for class imbalance straightforwardly whilst retaining solution in closed form however: multiplying each Frobenius norm term in the original objective of Equation (1) by (where np
the number of columns of Xp, Vp E C) leads to C, = (L-Ax,X; Equation (4).
Ejec ny xx,X]) in
"Corollary 4.3.39 of Horn and Johnson [28]. Note that all summands in C, are symmetric.

---

Special cases To contrast the proposed objective with related decompositions, it's instructive to consider the resulting subspaces for extreme values of X (for zero-mean data). In the limit case of À == 0 for example, W; is given by the top principal components of the data points for one partieular class Conversely, a value of À == gives the bottom principal components of datapoints in all other classes j E C \ (t). Thus, À can be seen providing a trade-off between hyperplanes well-capturing the variance of the attributes the target class and lying near-orthognnal to the points of the remaining classes. Finally, one recovers regular PCA when C; ;= Ejec By X,
2.2 From subspaces to submanifolds
choice Through CLIP's choice of the cosine similarity an objective function during training, the unit-norm
VL representations live on the hypersphere 2,, zT Sd C Rd [24]. However, subspace learning in the ambient Euclidean space R does not respect the underlying geometry of the manifold on which the data lie. An orthogonal projection guaranteed to result in vector that remains on the sphere, even if all the input data do. Motivated by this, we extend the component analysis for linear subspaces developed in Equation (1) to geodesic submanifolds [25]. As demonstrated in Fletcher et al. [25] for PCA, an analogous approximate projection onto the geodesic submanifolds capturing the desired variances can be made by applying the exact same component analysis of Equation (1) in the tangent space T C IR to the VL sphere data's intrinsic mean μ E sd-1 instead. To this end, we use the so-called Logarithmic Map Logp : g + Tpst which maps points on the sphere to the tangent space at a reference point e gd-1 and its inverse, the Exponential Map Expp Tpp - gd-1 to map points back onto the hypersphere (whose well-known definitions are provided in the supplementary material).
vector onto the learnt Euclidean subspaces is not
We can then compute the subspace of the tangent space to the intrinsic mean spanned by the columns of W. E Rdxk for word class i as the leading k eigenvectors of C, = E1 A)Log,, Logg (Xxn) - Ejeern ALog
We have again assumed an equal number of class data points purely for ease of presentation. This whole process is visualised in Figure 2.
By projecting onto the learnt subspaces of TuSd-1, one can better isolate or remove the visual attributes associated with part of speech i. To isolate or kill the attributes we compute the projection onto the column space (i) or orthogonal complements (ii) respectively with
(5) Projection onto the Euclidean subspaces can be computed using the projection matrices P, W.W. and P I P,- The way in which can extract representations relating to the visual modes of variation for the parts of speech is explored in detail in Section 3.
(i) I1, = E [W, Lz),
(ii) II (z) Exp,, (II W.W. Log, (z)).
Experiments
Here we present both qualitative (Section 3.1) and quantitative (Section 3.2) experiments to validate the model's ability disentangle the object a CLIP text or image representation from its appearance. We henceforth use 'subspace" to refer throughout to the manifold generalisation from Section 2.2.
use the following 4 parts of speech: nouns, adjectives, verbs, and adverbs. Our labelled data points (with which we compute the closed-form solution of Equation (4)) for these parts of speech are given by the WordNet [16] database. There are a total of 112219, 18021, 7295, and 3910 text-string data points from each of the categories respectively, after filtering out any word that appears in two more parts of speech. We set := 1/2 for all experiments. For all quantitative results, we use the base CLIP ViT-B-33 32 model. Please see the supplementary material for ablation studies on À and experiments on additional CLIP architectures.
Implementation details For all experiments,
3.1
Qualitative results
3.1.1
Visual disentanglement
Recent CLIP--assed text-to-image models (TTIMs) learn mapping from the CLIP embeddings to synthetic images depicting visually a text prompt [15, 29, 30]-a process that Menon et al. [13]
5

---

Prompt:
Prompt: "Cl culu Monet" "
Prompt: "A photo of snowy NYC"
Prompt: "A photo of
"David Hockney"
multicoloured penguss"
original
moun
adi.
Figure 3: The synthetic images from the original CLIP representations (top row) and when first projecting them onto the orthogonal complements of the noun and adjective subspaces to remove the 'content' and 'appearance" component, respectively.
show is prone to also inheriting task bias. We begin in this section by following the experimental protocol of Materzynska et al. [31], using a recent popular CLIP-based TTIM [15] from LAION to demonstrate visually how our PoS subspaces can succeed in predictably isolating visual variation in the CLIP representations pertaining to either the object described in a text prompt or its appearance.
As one motivating example, first study curious instance of 'visually polysemous' [14] natural language phrases-terms that have multiple visual associations. In particular, we find that when prompted with artists' names, TTIMs produce both artworks in their style and images of the person themselves (e.g. the top row of Figure 3). That is to say, CLIP entangles in its representation these two dual meanings of the artists-ther works' style and their physical appearance. We find that the PoS subspaces offer an intuitive way of reliably separating factors of visual variation in the representations for not just visually polysemous phrases, but also for natural language prompts more generally.
Concretely, projecting onto the orthogonal complement of the noun subspace II (Zz) successfully removes from the embedding visual information about the object/content described implicitly in text prompt T. For example, as visualised in row 2 of Figure 3 by reliably synthesising just artwork in artist's s style, by leaving just the snowy multicoloured appearance uppearance-based textures. On the other hand, projecting onto the adjective subspace's 's orthogonal complement IT (Zr) removes the visual appearances and styles associated with text description (row of Figure 3). For the visually polysemous artists' names, this isolates the representations of the artists themselves as humans-remen removing representations of their artwork styles. For the more complex prompts, this produces images of just the basic object described in the text prompt instead, such as the penguin or New York City. Many more examples of this visual disentanglement, details on the experimental setup, and ablation studies can be found in the supplementary material.
3.1.2 Style-blocking subspace projections
One societal concern with free-form TTIMs is their ability produce imitation artworks copying the style of artists. Here, we show how the learnt adjective subspace can be used as is as a step towards mitigating this. To achieve this, one simply modifies the TTIM forward pass first project the CLIP text representations onto the orthogonal complement of the adjective subspace with II; (ZT) before feeding it into the image generator. We see from the results in Figure 4 that this modification indeed prevents the imitation of the visual styles of range of artists (even with multiple forms of sentence structure in the prompt), whilst still enabling diverse set of images to be generated nonetheless.
Visual theme subspaces Whilst successfully preventing the visual imitation of many famous artists, applying the adjective subspace projection to every text prompt's CLIP representation can restrict the ability to use adjectives to specify visual appearance. We find further effective strategy to build additional subspaces for more specific visual appearances (c.g. artists' painting styles). Concretely,

---

Prompt: "A paanting of a mountain an the style of Van Gogh"
Prompt: *A Gauguin painting ing of Einstein"
original
aadi
Prompt: "A painting of The Eaffel Tower in the style of Rothko"
Prompt: "A portrait of woman en the style Roy Lechtenstesn'
ALA
original
adj
Prompt: "A David Hockney pasnting house"
Prompt: "A photo of the sky in the style of Van Gogh.
original
Figure 4: Killing the CLIP representations' component in the adjective subspace provides a way to block the imitation of artists' styles in CLIP-based text-to-image models.
we embed 830 artists' names and surnames in new matrix X and solve Equation (1) using all PoS classes the negative summation to prevent the destruction existing concepts. contrast to the adjective space, projection onto the orthogonal complement of this 'artist subspace' preserves adjective-basee visual descriptions whilst also successfully preventing style imitation (Figure Sa). Crucially, highlight that for the example shown in Figure 5a, the artist's name Qi Baishi is not present the "training" list of example artists, suggesting the subspace has learnt a more general notion of artist rather than simply the variation for only those artists whose names provided as supervision.
We suggest more generally that subspaces learnt from collection of words describing specific themes (whilst retaining variation in the PoS data through the main objective) could be useful for erasing entire visual concepts (such as NSFW imagery) from the CLIP representations. An additional example of another such custom subspace shown in Figure 5b for removing only gory/bloody visual appearances. Not only does this offer way to sit-to-image models, but might also offer application in discriminative tasks, such as being able to block CLIP-based retrieval of images of sensitive nature. Please see the supplementary material for additional details, results, and visualisation of failure cases.
specific appearances in -Lsed
Quantitative results
Here we show quantitatively how the PoS- eoS-ggrunded subspaces can isolate the variation in the CLIP representation of either an image or text prompt. validate this in two ways: through class invariance metric in Section 3.2. and through zero-shot classification in Section 3.2.2.
7

---

Prompt: "A painting of beach in the style of DE Basshs
Prompt: "A photo of a Tabbettooo bloody rabbst carcass"
original
original
Igapphc images censored]
artist
(a) custom subspace for 'artistic style".
(b) custom subspace gory/bloody visual themes.
Figure 5: Projecting onto the orthogonal complement of custom visual theme subspaces erases specific appearances from CLIP-based text-to-image models' images.
4110w/ Y,llf, for A; = frow normallsed)
AIIWW YillB, for (row normalised)
kllow Yolls i:: 64,
1.0 frow normalised)
0.43
Leants suttsracc
san
0:45
0.15
0.11
0.065
Sor category Nowr leb.
coroprry
0.52
0:15
2,092
0.42
9.24
0.22
2:12
0.39
0.28
3.17
0.16
0.56
3.081
0.22
5:22
0:38
0.25
6:35
3.21
0.14
0.20
0.12
0.30
Was
Fdleeds
Acaeciv
Advint
umbuddings Langent space 7
embeddings
tungent 7
empeddings
(a) [25] PGA for PoS of interest.
(b) Ours (A == 0.5).
(c) [25] PGA for nuisance PoS.
Figure 6: Subspace class invariance: The norm of the ViT-B-32 CLIP text representations of 5k
words from each PoS, in each of the subspaces. Results on baseline methods are shown in (a) and (c).
3.2.1 Class invariance
We first aim to quantify the extent to which our method results subspaces that capture variation solely in the desired part of speech. We quantify this by class invariance metric to measure how much each class' data points are retained in the subspaces. Concretely, we compute the Frobenius norm y [ Y, y where each column Yjn = LLgg,, (xjn) contains the CLIIP embeddings in the columns of X mapped to the tangent space, and ni is the number of data points in class j.
We compare the proposed method to two other component analyses performed in the tangent spaces. In Figure 6a we project onto a subspace learnt from only the data of the specific PoS of interest (e.g. the first row't 's subspace learnt through principal geodesic analysis [26] maximiiiis the variance for just the noun PoS data points), whilst in Figure 6c the subspace is learnt by simply minimizing the variance in the projections for the nuisance PoS classes (e.g. the first row's subspace minimizing the variance for the remaining adjective, verb, and adverbs' data points). We show the results of the proposed method with À = 0.5 in Figure 6b for all combinations of parts of speech.
This quantity should be as close as possible to each Figure 6's subfigures' off-diagonals i J and close as possible to along the figures' diagonals i (if the subspaces capture visual variation that unique to particular word class). The learnt subspaces Figure evidently exhibit this pattern of disentanglement better than the baselines, the vectors have large norm in their labelled class and a much smaller norm in the subspaces of the other categories.
3.2.2 Zero-shot subspace classification
In this subsection, our goal is to further validate quantitatively how well our noun subspace can isolate the representations relating to the content in an image by studying the task of sero-shot image
Table I: Top-1 ZS classification accuracy with CLIP ViT-B-32
MiTanaze Zg DenanNUF Soztred Canech
CHECKSS Ostind
SINIST
PCA
56.50
45.40
31.30
$0.10
13.00
63.58
25.10
37.00
PGA
26-00
45:20
$4.40
05.21
90000
16.10
09.23
23.10
34.20
30.50
22.40
39.08
Neen SchraastMM
$7.80
45:58
37.70
20.30
33.90
$1.90
76.30
$7.90
61.00
75.30
51.00
81.90
96.30
20.30
41.70

---

Top-1 ZS Accuracy
100
87.9
9226.
8487-7
$J.9
76.3
81.2
73
81.5
67.4
58.6
61.4
57.8
50
48.
42
38.5
44.7
45.5
39.3
43.
50.8
31,
19.8
30.3
Noun Subspace
Noun Submanifold
ShanfordCars
Caltech101
Food101
cifar10
1ffar100
OxfordPats
Flowers102
Callech256
St10
MNIST
FERZ013
MIT-states
ut-23p
ImageNET
DomainNET
Figure 7: Ablation study on the zero-shot accuracy for the subspaces vs the submanifolds with CLIP
ViT-B BLT-B-322 32; the submanifold outperforms the subspaces on almost all datasets considered.
classification', given this is very common application of CLIP in practice [1]. Importantly, these experiments serve as an additional way of measuring the subspaces' ability to isolate task-relevant modes of variation in the CLIP representations. With this in mind, we consider the baseline zero-shot setting [1] which computes the cosine similarity between all images in the training sets' and names of the class labels' CLIP representations. In our case, rather than computing the cosine similarity of the CLIP representations with S(z,, ZT) we measure instead the similarity in the noun subspace with S (I (z)), zr). . We hypothesise that if the noun subspace indeed better isolates the object of an image-invan inage-invariant to the particular style of the image-we should expect to see improvement to the baseline image classification.
We show the Top-1 accuracies for a large variety of datasets in Table 1. We find the noun submanifold projection to lead improved zero-shot classification on 14/15 of the datasets considered with CLIP ViT-B-32, and include a comparison to the Euclidean subspaces in Figure 7 to further illustrate the benefit of the geometry-aware variant. This is without needing any prompt engineering or domain knowledge about each dataset separately, confirming that the subspaces serve the intended role of being able to isolate the visual modalities of interest automatically. For all results in this subsection, we project onto a relatively large k == 500 dimensional subspace for PCA, PGA, and the proposed method. Please see the supplementary material for results on more alternative CLIIP architectures.
4 Related work
Vision-language representations There has been much interest in studying the properties of the VL. representations in large-scale models such as CLIP. In particular, Goh et al. [12] show that there exist neurons that fire response to both visual representations a concept as well as to text relating to the concept. Viewing this as a form of entanglement, Materzynska et al. [31] address this by learning a linear subspace in which written text is disentangled from its visual component. Whilst we also wish to disentangle visual concepts, representations, but rather visual modalities more generally. Further, our solution is instead given in closed form and has far fewer hyperparameters tune. In addition to disentangling written/visual concepts, a number of works explore other forms of disentanglement in multimodal models. For example, to better perform image captioning [35, 36), generation [37, 38, 39, 40, 41], discovering compositional representations or structure [37, 38, 42).
do not focus disentangling written words from visual
Another popular approach to learning more useful VL representations is fine-tuning; Ilharco et al. [43] use fine-tuning in combination with weight interpolation to improve results on specific tasks without affecting existing performance, whilst many other works fine-tune CLIP for specific domains such as action recognition [11], video recognition [10], image captioning [7], and more [9]. Despite the success of fine-tune fine-tuning, this comes with the restrictive requirement of task- sask-specific labels. The method of 'prompting' [44, 17, 18, 13] is one alternative approach. At a high level, this technique learns set of parameters (either in the form of 'words' in prompt [17, 44] as pixels appended to an input image [18, 13J) to steer the input to produce more useful representations for specific downstream tasks. In contrast, our method disentangles the modes of variation directly in the joint
Forr example, the colour in which a digit is drawn [33, 34] is not relevant information for the task of classifying which number it is.

---

vision-language representation space space-this facilitates the ability to separate semantic information in both image and text representations. Consequently, the proposed method has direct application for both discriminative tasks and CLIIP text-driven generative tasks.
Component analysis Let the matrices X X2 E R dddx contain n data points of two classes in their columns. The Principal Component Analysis (PCA) [32, 45] computes the low-dimensional subspace of maximum variance as the leading eigenvectors of the empirical covariance matrix of all data points. One pertinent drawback of PCA is its unsupervised nature in disregarding the labels of the data points. Whilst one can learn class slass-specific subspaces via PCA on the relevant subset of data (i.e. the eigenvectors of zero-mean ! xX,X; X ), there is nothing to prevent the remaining 'nuisance" class(es) from also having large variance in this learnt subspace. One method that provides a way to jointly maximise the variance in one class' projected embeddings whilst minimizing that of another class is the Fukumaga- Koontz transform [46, 47] (FKT), FKT learns a class 1-specific subspace spanned by the columns of W1 1 E Rdik as the leading eigenvectors of (UD- x, (UD- where U, D are the cigenvectors (stacked column- wise) and cigenvalues (along the diagonal) respectively of the matrix { + X²X,), ). Whilst FKT also learns subspace in which solely the target class' points have a large coefficient, the FKT operates on just two classes of interest and is more computationally expensive than the proposed method in requiring two eigendecompositions (rather than one). Another related supervised decomposition is the Fisher Discriminant Analysis (FDA) [48] which learns subspace in which classes can be easily discriminated. Despite FDA's objective involving a similar trace maximisation form to Equation (4), the goals of FDA and the proposed objective are very different. FDA aims to minimise intra-class variation, whilst the proposed objective maximisey the norm of vectors of the target class in the learnt subspaces, whilst minimising those of the remaining classes. Additionally, the proposed objective does not suffer from the same restrictively small upper bound on the dimensionality of the learnt subspace as FDA does through the low-rank of the between-scatter matrix. A comparison to the subspaces learnt with FDA, FKT, and the proposed objective is shown in the supplementary material to illustrate the differences visually.
5
Conclusion
In this paper, we have proposed a method for learning geometry-aware subspaces in CLIP's vision- language space that disentangle the modes of visual variation in representations of both images and text. To achieve this, we used the semantic relationship between parts of speech in natural language and specific visual modes of variation. We demonstrated the disentanglement qualitatively with a text-to-image model, showeasing the model's ability to remove visual imitation of artists' styles from synthetic images. Class invariance metrics and zero-shot classification results further validated the disentanglement quantitatively.
Limitations A common drawback of subspace learning approaches is choosing a good number of dimensions k. Our method inherits this limitation, and one must choose the appropriate value for the specific task. Despite this, the closed-form eigensolution means only single fast computation needed, and any desired number of eigenvectors can be used at test-time. Although the recovered subspaces show wide applicability in downstream tasks, they are not able to perfectly separate the modes of variation for every possible image and text prompt. Additionally, the PoS supervision can not help address polysemy within a particular part of speech (such as disambiguating between the bird/machine meanings of the word 'crane"). This further alludes to the promise of the custom subspaces in being able to target more specific visual concepts. Finally, often even minor changes to text-to-image models' text input or its representation produces very different output images [49]. As can be seen from our results, the subspace projection of the entire text representation similarly does not guarantee the preservation of the structure of the images generated from the 'original' prompts.
Acknowledgements
This research was partially supported by the EU's Horizon 2020 programme H2020-951911 A14Media project, a grant from The Cyprus Institute on Cyclone, and by project MIS 5154714 of the National Recovery and Resilience Plan Greece 2.0 funded by the European Union under the NexIGenerationEU Program.
10

---

References
[1] Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agar- wal, Girish Sastry, Amanda Askell, Pamela Mishkin, Jack Clark, Gretchen Krueger, and Ilya Sutskever. Learning transferable visual models from natural language supervision. In Int. Conf. Mach. Learn., 2021.
[2] Chao Jia, Yinfei Yang, Ye Xia, Yi-Ting Chen, Zarana Parekh, Hieu Pham, Quoe Le, Yun- Hsuan Sung, Zhen Li, and Tom Duerig. Scaling up visual and vision-langa saiin-language representation learning with noisy text supervision. In International Conference Machine Learning, pages 1904-4916. PMLR, 2021.
[3] Lu Yuan, Dongdong Chen, Yi-Ling Chen, Noel C. F. Codella, Xiyang Dai, Jianfeng Gao, Houdong Hu, Xuedong Huang, Boxin Li, Chunyuan Li, Ce Liu, Mengchen Liu, Zicheng Liu, Yumao Lu, Yu Shi, Lijuan Wang, Jianfeng Wang, Bin Xiao, Zhen Xiao, Jianwei Yang, Michael Zeng, Luowei Zhou, and Pengchuan Zhang. Florence: A new foundation model for computer 2021.
vision. ArXiv, abs/2111..1ssl.
[4] Robin Rombach, Andreas Blattmann, Dominik Lorenz, Patrick Esser, and Bjorn Ommer. High-resolution image synthesis with latent diffusion models. CVPR, Jun 2022.
[5] Katherine Crowson, Stella Biderman, Daniel Kornis, Dashiell Stander, Eric Hallahan, Louis Castricato, and Edward Raff. VQGAN-clip: Open domain image generation and editing with natural language guidance. In ECCV, pages 88 088-10, 2022.
[6] Or Patashnik, Zongze Wu, Eli Shechtman, Daniel Cohen- Or, and Dani Lischinski. StyleCLIP: Text-driven manipulation of StyleGAN imagery. In ICCV, pages 2085-2094, 2021.
[7] Ron Mokady, Amir Hertz, and Amit H Bermano. ClipCap: Clip prefix for image captioning. arXiv preprint arXiv:2/ 11222/1100999 1.09734, 2021.
[8] Yixuan Su, Tian Lan, Yahui Liu, Fangyu Liu, Dani Yogatama, Yan Wang, Lingpeng Kong, and Nigel Collier. Language models can see: Plugging visual controls in text generation. ArXiv, 044/2205.02655. 2022.
[9] Sheng Shen, Liunian Harold Li, Hao Tan, Mohit Bansal, Anna Rohrbach, Kai- Wei Chang, Zhewei Yao, and Kurt Keutzer. How much can CLIP benefit vision-and-languaae tasks? In ICLR, 2022.
[10] Bolin Ni, Houwen Peng, Minghao Chen, Songyang Zhang, Gaofeng Meng, Jianlong Fu, Shiming Xiang, and Haibin Ling. Expanding language-image pretrained models for general video recognition. In ECCV, pages 1-18. Springer, 2022.
[11] Mengmeng Wang, Jiazheng Xing, and Yong Liu. ActionCLIP: A new paradigm for video action recognition. ArXiv, abs/2109.08472, 2021.
[12] Gabriel Goh, Nick Cammarata f. Chelsea Voss t. Shan Carter, Michael Petrov, Ludwig Schubert, Alec Radford, and Chris Olah. Multimodal neurons in artificial neural networks. Distill, 2021. doi: 10.2391 5/distill.00030. https://distilllpub/Z2 2aab22021/mmtiinnaa--eeeoo
[13] Sachit Menon, Ishaan Preetam Chandratreya, and Carl Vondrick. Task bias in vision-lan laagunllnguuage models. ArXiv, abs/2212.044111 2022.
[14] Yazhou Yao, Jian Zhang, Fumin Shen, Wankou Yang, Pu Huang, and Zhenmin Tang. Discov- ering and distinguishing multiple visual senses for polysemous words. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 32, 2018.
[15) Dominic Rampas, Pablo Pernias, Flea Zhong, and Mare Aubreville. Fast text-conditional discrete denoising on vector-quantized latent spaces, 2022.
[16] George A. Miller. WordNet: lexical database for english. Commun. ACM, 38(11):39 nov 1995. ISSN 0001-0782.
[17] Kaiyang Zhou, Jingkang Yang, Chen Change Loy, and Ziwei Liu. Conditional prompt learning for vision-language models. In CVPR, pages 16816-16825, 2022.
[18] Hyojin Bahng, Ali Jahanian, Swami Sankaranarayanan, and Phillip Isola. Exploring visual prompts for adapting large-scale models. arXiv preprint arXiv:2203.17274 2022.
[19] Alec Radford, Luke Metz, and Soumith Chintala. Unsupervised representation learning with deep convolutional generative adversarial networks. ICLR, 2016.
11

---

[20] Erik Härkönen, Aaron Hertzmann, Jaakko Lehtinen, and Sylvain Paris. GANSpace: Discovering interpretable GAN controls. NeurIPS, 33:9841-9850 2020.
[21] Yujun Shen and Bolei Zhou. Closed-form factorization of latent semantics in GANs. In CVPR, 2020.
[22] Christos Tzelepis. Georgios Tzimiropoulos, and Ioannis Patras. WarpedGANSpace: Finding non-linear RBF paths in GAN latent space. In ICCV, 2021.
[23] Yue Song, Jichao Zhang, Nicu Sebe, and Wei Wang. Householder projector for unsupervised latent semantics discovery. In ICCV, 2023.
[24] Tongzhou Wang and Phillip Isola. Understanding contrastive representation learning through alignment and uniformity on the hypersphere. In Int. Conf. Mach. Learn. JMLR.org, 2020.
(25) P.T. Fletcher, Conglin Lu, S.M. Pizer, and Sarang Joshi. Principal geodesic analysis for the study of nonlinear statistics of shape. IEEE Trans. Med. Imag., 23(8):995-1005, 2004.
[26] Thomas Fletcher, Conglin Lu, and Sarang Joshi. Statistics of shape via principal geodesic analysis on lie groups. In CVPR, volume I, pages I-I, 2003.
[27] Stefan Sommer, François Lauze, Søren Hauberg, and Mads Nielsen. Manifold valued statistics, exact principal geodesic analysis and the effect of linear approximations. In ECCV, pages 43-56. Springer, 2010.
[28] Roger A Horn and Charles R Johnson. Matrix analysis, 2nd Ed. Cambridge university press, 2012.
[29] Aditya Ramesh, Prafulla Dhariwal, Alex Nichol, Casey Chu, and Mark Chen. Hierarchical text-conditional image generation with CLIP latents. ArXiv, abs/2204.061 226122220..002,....2. 2022.
[30] Zihao Wang, Wei Liu, Qian He, Xin Wu, and Zili Yi. CLIP-GEN: Language- free training of a text-to-image generator with CLIP. ArXiv, abs/2203.00386, 2022.
[31] Joanna Materzynska, Antonio Torralba, and David Bau. Disentangling visual and written concepts in CLIP. CVPR, pages 16389-16398, 2022.
[32] Harold Hotelling. Analysis of complex of statistical variables into principal components. Journal of educational psychology. 24(6):417, 1933.
[33] Martin Arjovsky, Léon Bottou, Ishaan Gulrajani, and David Lopez-Paz. Invariant risk mini- mization. arXiv preprint w907vx190..028900 2019.
[34] Andrea Vedaldi. Invariant representations and learning for computer vision. PhD thesis, University of California, 2008
[35] Aditya Deshpande, Jyoti Aneja, Liwei Wang, Alexander G. Schwing, and David Alexander Forsyth. Fast, diverse and accurate image captioning guided by part-of-speech. CVPR, pages 10687-10696, 2018
[36] Shweta Mahajan and Stefan Roth. Diverse image captioning with context-object split latent spaces. NeurlPS, abs/2011.00066 2020.
[37] Hila Chefer, Oran Lang, Mor Geva, Volodymyr Polosukhin, Assaf Shocher, Michal Irani, Inbar Mosseri, and Lior Wolf. The hidden language of diffusion models, 2023.
[38] Zihao Wang, Lin Gui, Jeffrey Negrea, and Victor Veitch. Concept algebra for saore-based conditional model. In ICML 2023 Workshop on Structured Probabilistic Inference Infferen & Generative Modeling, 2023.
[39] Matthew Trager, Pramuditha Perera, Luca Zancato, Alessandro Achille, Parminder Bhatia, and Stefano Soatto. Linear spaces of meanings: Compositional structures in vision-language models, 2023.
[40] Jan Zuiderveld. Style-content disentanglement in language-image pretraining representations for zero-shot sketch-to-image synthesis, 2022.
[41] Ian Huang, Panos Achlioptas, Tianyi Zhang, Sergei Tulyakov, Minhyuk Sung, and Leonidas Guibas. LADIS: Language disentanglement for 3D shape editing. In Findings of the Association for Computational Linguistics: EMNLP 2022, pages 5519-5532, Abu Dhabi, United Arab Emirates, December 2022, Association for Computational Linguistics. doi: 10. 182222v findings-emmlp.044.
12

---

[42]
Tian Yun, Usha Bhalla, Ellie Pavlick, and Chen Sun. Do vision- langual pretrained models learn composable primitive concepts? Transactions on Machine Learning Research, 2023. ISSN 2835-8856.
[43] Gabriel Ilharco, Mitchell Wortsman, Samir Yitzhak Gadre, Shuran Song, Hannaneh Hajishirzi, Simon Kornblith, Ali Farhadi, and Ludwig Schmidt. Patching open-vocabulary models by interpolating weights. NeurIPS, 2022.
[44] Kaiyang Zhou, Jingkang Yang, Chen Change Loy, and Ziwei Liu. Learning to prompt for vision-language models. IJCV, 13009):3377-2443 2022.
[45] Karl Pearson. Lii. on lines and planes of closest fit to systems of points in space. The London, Edinburgh, and Dublin philosophical magazine and journal of science, 2(11):55,-57, 1901.
[46] Keinosuke Fukunaga. Introduction statisfical paltern recognition. Elsevier, 2013.
[47] Sheng Zhang and Terence Sim. Discriminant subspace analysis: A fukunaga-koome approach. IEEE Transactions on Pattern Analysis and Machine Intelligence, 29, 2007.
[48] R. A. Fisher. The use of multiple measurements taxonomic problems. Annals of Eugenics, (2):179-188, 1936.
[49] Amir Hertz, Ron Mokady, Jay Tenenbaum, Kfir Aberman, Yael Pritch, and Daniel Cohen-Or. Prompt-to- trompttto-pompt image editing with cross attention control, 2022.
[50] Mehdi Cherti, Romain Beaumont, Ross Wightman, Mitchell Wortsman, Gabriel Ilharco, Cade Gordon, Christoph Schuhmann, Ludwig Schmidt, and Jenia Jitsev. Reproducible scaling laws for contrastive danguage-image image learning, 2022.
[51] Long Ouyang, Jeffrey Wu, Xu Jiang. Diogo Almeida, Carroll Wainwright, Pamela Mishkin, Chong Zhang, Sandhini Agarwal, Katarina Slama, Alex Ray, et Training language models to follow instructions with human feedback. NeurlPS, 35:27730-27744 2022.
[52] Rohit Gandikota, Joanna Materzynska. Jaden
and David Bau. Erasing concepts from diffusion models. arXiv preprint 0tti:23033003444 2023.
[53] Nupur Kumari, Bingliang Zhang, Sheng-Yu Yu Wang, Eli Shechtman, Richard Zhang, and Jun-Yan Zhu. Ablating concepts in text-to-image diffusion models. arXiv preprint arXiv:2303. 13516, 2023.
13

---

A Definitions and derivations
A.1 Closed-form solution
Detailed steps for the expansion of the original objective into the trace maximisation form of the main objective are given as follows:
(1 - W)] X E X
(6)
jECK(O
=(1 AJU (W, X.) T ((Txx))
Σ AIr ( (W?X,))
(7)
SECVE)
=tr((1 x)X W. W. Σ A.W.W.XX
(8)
SECMO
-tr((1 ! X,X, W; Aw X w.)
99)
jECMA
-t((W, ((1 - XIXXX
Σ
x W.)
(10)
jEC(())
-Ir(W, C.W.)..W.),
(11)
where C, ((1 Ejerm XX,XJ). Here we have used | (X X) and the
linearity and cyclic properties of the trace.
A.2 The Logarithmic and Exponential Maps
For mapping to the hypersphere's tangent space reference point in the main paper, we well-known explicit formulas. Concretely, the Logarithmic Map Logp gd-1 - T,Sd-1, which maps points the sphere to the tangent space at reference point p Sd-1 is defined
Logp(z) (2) arrcos(2 p)) (Ia pp [zz - p) [[[ pp (zz p2
(12)
Its inverse, the Exponential Map Expp TpSd-1 + gd mapping points back onto the sphere is given by
Exp, (z) cos (||z|12) p + sin (1|z (zz] ||z||2
(13)
B Additional results
B.1 Qualitative results
Visual disentanglement Firstly, we include many more examples the visual disentanglement
with the 'adjective' and 'noun' PoS subspaces and TTIM of Rampas al. [15] in Figures 8 and 9.
14

---

Prompt: "Claude Monet"
original
32
adj.
768
Prompt: MM. Escher"
original
moun
k=
adi.
k-768
Prompt: "Jackson Pollock"
original
noun
k=
k=768
adi.
Prompt: "Katsushika Hokusai"
original
noun
adj.
Figure Additional results for visual disentanglement of text prompts using the learnt PoS subspaces.
15

---

Prompt: photo of Värginia Woolf in the style of Impression
original
noun
k= 768
adi.
k= 766
Prompt: "A photo of Karl Marz in disney movie"
original
noun
k= 768
adi.
Prompt: "A photo of sunny city"
origina
noun
k= 768
adi.
767
Prompt: "A photo of pink croissant"
original
noun
k=768
adi.
768
Figure 9: Additional results for visual disentanglement of text prompts using the learnt PoS subspaces.
16

---

Visual theme removal As shown in the main paper. the adjective subspace works remarkably well for preventing the imitation of artists' styles in the CLIP-based text-to-image model Paella. However, as stated in the main paper, the adjective subspace orthogonal projection for the task of "style blocking" is overly restrictive in also preventing the description visual appearance with adjectives. We provide in Figure 10 some examples of this-for example, the 'stormy" and 'red' visual appearances are removed in Figure 10 after projection. On the other hand, the custom visual theme subspaces can target specific visual appearances more precisely-two examples are shown in Figure (following the experimental setup outlined in Appendix D).
Prompt: photo of shaba outside en stormy weather"
Prompt: "A photo of a house in the forest wi th red walls"
original
Figure 10: 'Style blocking' with the adjective subspace is overly restrictive (here blocking 'stormy' and 'red' visual appearances).
Prompt: "A photo of covered in b blodd"
Prompt: "A photo of gruesome death metal album cover"
original
Igraphic images censored]
Prompt: Shiba Inu the style of Van Gogh"
Prompt: portrait painting of man in the style of Picasso"
original
artist
Figure 11: Additional results for the custom visual theme orthogonal complement subspace projection for 'gore' and artists' styles.
17

---

Prompt: "A photo of crane"
original
- 512
Project onto:
"animal" subspace
Prompt: "A photo of bass"
original
Project
512
'animal" subspace's
orthogonal
complement
Figure 12: Projecting onto custom subspace (given by 2758 names of animals) and its orthogonal complement learnt using the proposed objective. Such custom visual subspaces show promise in helping disambiguate between polysemous nouns.
Polysemy within single part-of-speech As described in the limitations, the PoS subspaces cannot disambiguate between polysemous phrases within one particular PoS. show in Figure 12 proof-of-concee result suggesting that the custom visual subspaces can be means of addressing this. In particular, we learn a custom "animal" subspace following the same protocol in Sect. 3.1.2 of the main paper. When projecting CLIP representations of "a photo of crane" onto this subspace, produce photos of the bird, rather than machinery. Conversely, projecting the CLIP representation of "A photo of bass" onto this subspace's s orthogonal complement removes the representation of "bass" as fish, synthesizing instead just images of bass guitars.
B.2 Quantitative results
Visual theme subspace invariance Here we show quantitative results for the visual theme-specific subspaces. We have evaluated this visually via text-to-image models in Figure 11, however here we wish demonstrate that large variation in the CLIP representations directly is captured for only the themes of interest. Concretely, in Figure 13 we compute the same class invariance metric for 200 random WordNET words and random theme-specific words in the learnt custom theme subspaces through 200 Y.IP. Here, Y E dxx200 contains in columns the CLIP word embedding mapped to the tangent space, and denotes the specific custom visual theme of interest for a particular subfigure. As can be seen from the high magnitude bars in Figure 13, these subspaces map the 200 random other words much closer to the zero vector than the theme-specific words. This indicates the variance in just the words of interest has indeed been captured.
orange bars and low magnitude of the blue
18

---

Artists' subspace, k 0.5
Nude subspace, 6= =.5
subspace, = 0.5
0.4
2illWW Vilii
1al0 villd
0.4
Shll VIIi
0.3
0.2
Figure 13: 200 [I( Y p of CLIP representations (of both 200 random words and 200 words from the 'training set describing the theme of interest) projected onto theme i-specific subspaces.
1
Additional zero-shot classifcation We show in both Table 2 and Table additional results for the baseline zero-shot classification protocol (following the exact same setup in the main paper) with the similarity metric (Zr), 2r) after the noun subspace projection. As can be seen, the proposed subspace leads to improved zero-shot classification on a wide range of datasets, for multiple CL.IP architectures.
Table 2: Top-1 ZS classification accuracy with CLIP ViT-B-16
EmugeNEF
AlT--aales
DomniinNEE NET
Caloeh101
DIANKO 000000
Flowers102
Callehh26
UT Zag-
Rood101
CIEARIO
FER2013
STLIO
AINIST
CLIP
61.00
47.30
89.10
54.40
62.50
82.00
$1.50
88.80
62,40
76.10
65.20
81.70
96.90
48.00
41.90
PCA
61.61
89.00
54.40
62.50
81.50
62,30
97.00
PoS PGA
61.80
47.70
89.60
54.30
60.00
82.20
81.70
87.90
62.70
60
82.3
96
50.00
42.70
Noun Submanifold
62.80
48.30
68.10
54.70
62.70
82.90
$2.10
89.10
63.90
77.00
65.40
83.40
97.00
55.00
48.60
Table 3: Top-1 ZS classification accuracy with CLIP ViT-L-14.
ImageNET
MIT-states
Zup.
DomainNET
StanforiCar
Caltedh101
Food101
CIFARIO
SEARION 000
OxfordPets
Flomess102
Caltech256
FER2013
STL.10
CLIIP
69:00
$1.80
90.40
59.60
74.70
80.90
87.40
91.70
72.70
82.50
74.60
86
86.80
97.70
59.70
35.70
PoS PCA
69.00
51.80
90.40
59
74.70
80.90
87.40
91.70
72.70
82.50
74.60
36
97.70
59.70
35.70
Noun Submanifold
70.10
$2.50
90.10
60.00
76.00
82.80
87.70
90.60
73,90
83.10
74.70
$8.10
96.90
$8.90
46.40
C Ablation studies
C.1 Relationship to alternative component analyses
We first compare ID subspaces learnt with our method, FDA [48], and FKT [46] shown in Figure 14 on toy data chosen to illustrate the qualitative differences in the properties of the subspaces. Given the very different goals of FDA in minimising intra-class variation, the resulting FDA subspace is oetrrooth to that of FKT and the proposed method. Whilst the FKT-given subspace is very close to ours, this particular illustrative toy data our subspace better kills the variance data (as illustrated in Figure 14 b.iii). This figure also provides visualisation of the learnt subspace's proximity to the principal component of the target class and the bottom principal component of the red class' datapoints proximity to the two extremes being controlled by X.
red
19

---

(b.i)
(b.ii) FKT
(b. Ours
(a) Learnt subspace (with 0.5)
1e-2
1e-2
1e-2
0.05
2
2
Z
0.04
ZA
1
1
PCA1
0.03
PCAB
0
0
0.02
FDA
FKA
-1
-1
-1
0.01
Ours
-2
-2
-2
0.00
-3
-3
-3
-0.01
-4
-4
-0.02
-0.04
-0.02
0.00
0.02
0.04
Figure 14: (a) A visual comparison of the leading eigenvector of C to the first FDA component (centred for comparison), to the first FKT component. Shown (b) are the points' coordinates the three subspaces. As be seen, the learnt WB1 captures large variance in the blue target class and is close to orthogonal to data points of the red class.
C.2
Role of k
We show the impact various choices & (dimensionality the subspaces) as visualised with text-to-image models in Figure 15 with the projections onto the orthogonal complements to kill the undesired variation. As can be seen, increasing removes more and more visual information relevant the particular visual mode. For example, see the image feature increasingly less snow the right, whilst increasing less of London on the left.
Prompt: "A photo of snowy London" "
original
II (ZT) (remove component)
II (ZT) (remove adj. component)
k=256
ablations
<67 k-512
Figure 15: Ablation study the value of & on the d = 1024 OpenCLIP VL space when projecting onto the orthogonal complements of k-dimensional adjective and noun subspaces.
20

---

Prompt: "A photo of cup of cranberry juice"
Prompt: "A photo of a bloody rabbit carcass"
original
Igraphic images censored]
gere
Gov 6 e
0.5
Figure 16: Without using PoS as 'negative guidance' (i.e. when X == 0), related concepts (e.g. "cranberry juice') can be visually removed a much greater extent than when using the PoS guidance (A = 0.5).
C.3 Role of X
We next provide an ablation study on the value of We provide both a visual qualitative ablation and quantitative one.
Qualitative Concretely, in each subfigure (row) of Figure 17, we take the first 5000 WordNET text strings from each part of speech and compute their CLIP text embeddings 27 E Rdd. We then calculate W Log (2r). plotting the first coordinate along the æ-axis and the second along the y-axis each subfigure in Figure 17. Ideally, the data points in the target class should be the only ones with large norm this hyperplane captures visual variation that is unique to a particular word class. We see that À := 0 preserves the most variance in the target class' embeddings but the different categories' projections are clearly entangled the other classes' datapoints also have large norm. Conversely, À = 1.0 maps all points effeetively to the zero vector-killing the variance in all categories. As can be seen in Figure 17c, À == 0.5 offers reasonable balance of both properties in this 4-class setting. The exact same experiments conclusions can be drawn about the practical impact of
the larger version of CLIP, shown in Figure 18, where similar
Quantitative For quantifying this in more dimensions, we compute the class invariance metric (used in the main paper) in Figure 19 and Figure 20 for various values of X, where we observe that = 0.5 a sensible choice for multiple CLIP architectures.
Visual subspaces Finally, we demonstrate the importance of using PoS as 'negative examples' in the summation in the main objective when learning visual theme-specific subspaces. Intuitively, whilst we want to maximise the variation for phrases particular theme (such as 'gory'), ) we also want to preserve the ability to generate other concepts with the TIIM, which is what the objective provides through the hyperparameter X.
In particular, we show in the second row of Figure 16 the visual results when projecting onto the orthogonal complement a 'gory' subspace learnt when we not use PoS as 'negative guidance' (i.e. when X : 0). As can be seen in comparison to the third row of Figure 16, using the PoS is critical this instance for retaining the ability to synthesise existing related concepts (here ensuring e.g. 'cranberry juice' still be synthesised even though visually 'gory' appearances are removed).
21

---

Noun-specific space, sppecfive-peedff space.
Verb-specific space,
Adverb-spedific space.
0.4
-04
-0,4
-0.4
-0.50 -0.25
0.00
0.25
0.50
-0.50
-0.25
-0.50
0.00
0.25
0.50
Mo/Lop
Wk.Logg,t)
(a) À
Noun-specific space, A 0.25
Adjective-specffcc space, 0.25
Verb-specific space, A 0.25
Adverb-specific space, Á 0.25
we Cel
0.0
0.0
0.0
0.0
-0.2
-0.2
-0.2
-0.
-044
-0.4
-0.4
-044
0.00
-0.50
Mu(Log,tz)
Wo(Log
Wi/tog,1e)
We(cogg1x)
(b) À
0.25
Noun-specffic
0.5
Adjective-specific space. 0.5
Verb-specific space. 0.5
Adverb-speciffc
0.5
0.4
0.4
0.4
0.4
0.2
Walloguizi
0.2
0.2
0.2
0.0
-0.50 -0.25
0,00
0.25
0.50
-3.00
-325
0.00
0.25
0.50
-0.50
-0.25
0.00
0.25
6.50
-0.50
00.25
0.00
0.25
0.50
(c) A
speclfieciicc space,
Adjective-ppecht space,
Verb-specific space, 0.75
Adverb-specific space, A
Mollog
-04
-0.4
-044
#u(cog,(k)
(d) =
0.75
Noun specific space, - 1.0
Adjective space, 1.0
Verb specific space, À 1.0
Adverb specific space, A 1.0
0.2
0.2
0.2
0.2
0.0
0.0
0.0
0.0
0.2
0.2
0.2
0.2
-9.4
-0.4
-0.4
-0.4
-0.50
-0.25
0.00
0.25
0.50
-0.50
-0.25
0.00
0.25
0.50
-0.50
-0.25
0.00
0.25
0.50
-0.50
-0.25
0.00
0.25
0.50
WulLogg.R)
Wr.Logg(30
W./Log,(2)
WeiLog,12)
(e) := 1.0
Figure 17: Embeddings' first two coordinates in the tangent space(es), with various values of À in the main objective (axis limits are fixed to compare length of vectors across values A). The base CLIP model Alip-vit-base. base-patch32 is used here.
22

---

Noun-specific space, sppecfive-peedff space.
Verb-specific space,
Adverb-spedffic space.
6.4
0.4
Weldoguies
-04
-0,4
-0.4
-0.50 -0.25
0.25
0.50
-0.00
-0.25
-0.50
0.00
0.25
0.50
Wo]Lop,00
W.(oogg(R)
We.Logg,t)
(a) À ==
Noun-specific space, A 0.25
Adjective-specffcc space, à 0.25
Verb-specific space, A 0.25
Adverb-specific space, A- 0.25
ie del
0.0
0.0
0.0
0.0
-02
-6.2
-0.2
-0.
-04
-0.4
-0.4
-044
-0.50
Mu(Log,tz)
Wo(Log,(z1
Wijtog,1e)
We(cogg12)
(b) À
0.25
Noun-specffic
0.5
Adjective-specific
=
Verb-specific
0.5
Adverb-speciffe
0.5
0.4
0.4
0.4
0.4
0.2
Malloguizi
0.2
0.2
0.2
0.0
0.0
-0.50 -0.25
0,00
0.25
0.50
-3.00
-325
0.00 0.25
0.50
-0.50
-0.25
0.00
0.25
6.50
-0.50
00.55
0.25 Molooggtt)
0.00
0.50
(c) A
Noun-specific apace,
Adjective-ppecti space, A Verb-specific space, A 0.75
Adverb-specific space, A
-04
-0.4
-044
#u/cog,(k)
(d) =
0.75
Noun specific space, A 1.0
Adjective space, 1.0
Verb specific space, À 1.0
Adverb specific space, A 1.0
0.2
0.2
0.2
0.0
0.0
0.0
0.0
0.2
0.2
0.2
0.2
-9.4
-0.4
-0.4
-0.4
-0.50
-0.25
0.00
0.25
0.50
-0.50
-0.25
0.00
0.25
0.50
-0.50
-0.25
0.00
0.25
0.50
-0.50
-0.25
0.00
0.25
0.50
WulLogg.R)
Wr.Logg(30
W./Log,(2)
WeiLog,121
(e) A
1.0
Figure 18: Embeddings' first two coordinates in the tangent space(es), with various values of À in the main objective (axis limits are fixed to compare length of vectors across values A). The larger CLIP model clip-vit- writ-large-ppp peeeeeppchh4444 is used here.
23

---

HiW YAll, fark; 64,A; 0.0 frow norma Food)
H/WW YJIE far - 64,4, 001 fro sormalsed)
Lewnt cilggere W. fo cetegrryy
944
9.23
6:21
2.22
Leantt sihgperre W. corestryyy
2:47
1:2
64
2.12
Learn: sutteaae Wi for carsury
033
0:31
0:3
4.5
133
0:37
0.22
7:33
3.2
6:24
0.27
9:24
9.2
0:22
2.35
2.26
0:25
0.23
925
1.26
0.24
0:24
0.14
3.38
815
CLP ombboddnng Y the targent sppt11
CUP ambudd
CLI ambuddings the tangent 1got-1
(a) A == 0
(b) À == 0.1
(c) A = 0.25
How Yau?, for 2o 64,4 - 3.5 grow normalieed
E:lWW Yoli fork: - 64,1; 0.75 frww namaa ised
HIEWW for k: 54, A yrow normel bedd
EAArTT sutepare Me for rategryy
Louam Noumssullppe sullppac W. for cilopory
Wi catopryy Adci
0.15
3.12
0.45
0:22
0:35
6.03
0:33
0:33
0,2
0.3
0.24
3.22
3.22
64
6:292
0.22
3.25
3
42
Learn
0:32
0.54
6.11
6.11
0.58
5:41
0.22
3:21
3:35
Anves
Marter Uie
New
Vee
Jahcc
CUP enbediinga Y, In the langert space 1,4"11
CLP embeeddningg Y, in the tungent space Xp5h11
CUP empodd ngs Y, Uhe langert space 7,5711
(d) A == 0.5
A=) 0.75
(i) A == 1.0
Figure 19: Ablation on À with the quantity - (I( Y,,Y, MP introduced in the main paper. Row- normalisation is performed highlight the relative representation of each class' embeddings within each subspace. The base CLIP model clip-vit- -atett--bba----ahh222 patch32 is used here.
n;
1 YAE fank 6 (row norms leed)
[1009 YIIE Ao 64,A) 0.2 [rw soemsleed
Leand tubgurre W the carogry
0G22
3.45
Lraent suppare fyr camporyy
0.5L
32
6:24
LeaTE pnoopen W. W. catepoy
0:23
0:44
3.07
2.58
4:35
0:14
621
1
6:58
2:2
83
3.33
2:28
3.24
0:33
3:26
0:21
3.2%
828
222
1:24
0.11
6.22
3.28
CUP orbbodiing in the targert 2
CUP anb thetaarge space 7
CUP anbeddinge Y, the tangent 1,0t+
(a) A == 0
(b) A == 0.1
(c) À == 0.25
How Yar?. for At 64, grow normaliedt
É/1WW) Yoll? fora:: in 66, 075 gow norma loeds
EIOW
[eint oitopare W. for cempoay
bount sutopace Wi for caapayy
D:577
9:49
0.31
6/40
0:35
6/7
0.24
6.5M
03
6:37
9.60
0/22
2.14
04
6,00
67
602
0.246
0.82
5.24
0:22
5.11
Aivs
Neu
Abedvve
Mive
Adecch
CUP embedsingg in the iangent spnce 7
CUP embeedings Y, the bongent space X
CUP embeddings Y. dhhhetngentssoe space 1,57-1
(d) A = 0.5
A 0.75
A== 1.0
Figure 20: Ablation on À with the quantity 4 I| Y, MI introduced in the main paper. Row- normalisation is performed highlight the relative representation of each class' embeddings within each subspace. The larger CLIP model clip-vit-large patch14 is used here.
D Experimental details
For reference this section, we first include the dimensionalities of the shared VI. spaces and public links to implementations used of the three CLIP models in this paper in Table 4.
24

---

Table 4: Dimensionality of the VL space representations in the four CLIP models.
Model name
clip-vit-ban base baze-patch52
clip-vät- baze-aathhe-
clip-vit- large-patch11
"OpenCLIP"
Dimcnsionalitty of 21, Public link
512
512
768
1024
HaggingFace
FoggingFace
HaggingFace
Githuh
Visual disentanglement The Paella TTIM [15] used in the main paper adopts the 'OpenCLIP" [50] model with a larger d = 1024-dimensional VL representation. For all 'visual disentanglement results throughout both the paper and supplementary material, 'noun' subspaces for all text prompts (apart from when removing the 'content' representations in visually polysemous phrases, where we find only k 32 components are necessary).
k = 768 dimensional 'adjective' and
Visual theme subspaces For the custom visual subspaces, we produce a list of phrases related to the visual theme of interest by asking ChatGPT [51] questions of the format: Please give me a list of 250 words and phrases related to the concept of (x), where x is the visual con- cept of interest (such as "gore"). For the case of the artist subspace, we ask: Please give me list of 250 of the most famous painters and visual artists of all time. In each scenario, we follow up twice more asking for additional responses (given the limited re- sponse length), specifying that it tries not to repeat any of the previous answers in the list. For the experiments in the "gory' and 'artist' custom subspaces, ChatGPT gave 371 and 830 unique phrases respectively (taking just the provided artists' surnames as additional examples for the latter), and use a 128- and k 512-dimensional subspace respectively (given the limited number of phrases for the gore subspace provided by ChatGPT).
Concurrent work Recent preprints [52, 53] explicitly address the task of ablating particular concepts in diffusion models specifically. However, in contrast to the proposed method, these concurrent works fine-tune Stable Diffusion-specifii [4] submodules, and do not focus on the final CLIP vector representations. Thus, there is no straightforward way to compare the proposed method working in CLIP's shared vision-language space directly nor the alternative Paella [15] THIM. One methodological benefit to [52] over the proposed method however (purely in the context of text-to- image synthesis) is in the requirement of only a single text prompt describing a concept, relative to necessary collection'. On the other hand, our subspaces are learnt in closed form-for example, the 'gory' subspace takes only 0.28 seconds to compute on a V100 GPU, given the CLIP embeddings. This is in contrast to [52]'s models which are stated to require 1000 gradient descent steps to compute, and [53] taking 5 minutes per concept.
Compute time and hardware To run the Paella model, use 32GB NVIDIA Tesla V100 GPU. Learning the subspaces is particularly fast given the closed-form solution, taking just 1.1 seconds to compute all 4 (noun, adjective, verb, and adverb) PoS subspaces. Encoding all WordNet PoS examples with CLIP takes 28.91 minutes, however, this is a fixed cost and only needs to be done once the beginning (after which any number of additional subspaces can be computed very quickly).
'In particular, n phrases' embeddings can span subspace with maximum of dimensions
25


Reviews:
[{"review_id": "FdcBuLKQu7", "reviewer": "Reviewer_3FWH", "summary": "This work proposes to learn subspaces for disentangling the visual representation in the CLIP space, based on the parts of speech of the prompt. A closed form solution is presented where the norm corresponding to the embedding of word of interest has a maximum norm while the norm of the rest is minimized. Qualitative results are shown on the  CLIP-based TTIM from LAION where visual results are presented by killing on of the subspaces (noun or adjective) and quantitative through performance on a class invariance metric and through zero-shot classification. The method performs better than the prior art.", "questions": "1. How would different partial prompts in the original baseline model compare with the proposed approach as pointed to in weakness?\n2. Are there insights into persevering the underlying style of the image generated from the prompt? Example removing only snow from the already generated \"snowy\" images of NYC? \n", "limitations": "There is no potential negative societal impact of their work.", "rating": 7, "confidence": 5, "soundness": 3, "presentation": 3, "contribution": 3, "strengths": "+ The work is very well written, clearly motivated and well presented. \n+ This is the first work which attempts to disentangle the subspaces using POS in CLIP based embedding models. \n+ The method is easy to implement with the closed-form solution. \n+ Qualitative and quantitative evaluation are performed to show the utility of POS guided subspace projection. \n", "weaknesses": "- Effect of the prompts: From the quantitative results the role of the subspaces is not clear. For example, by removing noun from \"Van Gogh\" it generates the painting. Painting is also a noun. Therefore, the distinction is not clear.\n\n- In the qualitative examples (Figure 5), the images also change and the semantics on removing one POS subspace do not guarantee that the original image's style is preserved. \n\n- It would be good to show the results with multiple samples from the given prompt on the original dataset to show if the method actually works or just picks up on the partial prompts which would also work with the baseline model.  For example, \"A mutlicolored Penguin\" and \"A penguin\" are very general prompts and they can have similar results without the subspace projection.\n\n- \"Disentanglement\" in multimodal approaches has been presented in prior work [1,2]. \n1.  Fast, Diverse and Accurate Image Captioning Guided By Part-of-Speech. CVPR 2019. \n2. Diverse image captioning with context-object split latent spaces.", "quality": null, "clarity": null, "significance": null, "originality": null, "strengths_and_weaknesses": "", "was_revised": false, "final_justification": "", "rebuttal": "We thank the reviewer for their assessment of the paper as “clearly motivated” and “very well written”. We address below the weaknesses raised and answer the two questions asked:\n\n\n- `Effect of the prompts: From the quantitative results the role of the subspaces is not clear. For example, by removing noun from \"Van Gogh\" it generates the painting. Painting is also a noun. Therefore, the distinction is not clear.` \n\n    * We respectfully argue that the distinction is clear from our qualitative results. In particular, whilst “painting” is indeed a noun, we do not see any generated “object” instantiation of a painting present *within* the image in Row 2 of Fig. 1, but rather an image with the visual styles associated with the artist. Of course, any non-blank synthetic image will always contain *something* one could call a noun (and ultimately we still see an “image”*,* even though “image” is also a noun), **but crucially this doesn’t refute our claim made in the paper about the specific roles of the subspaces** (e.g. [L199]): that the adjective subspace captures “appearance-based variation” associated with a text prompt, and the noun subspace that of the “objects” described by a text prompt.\n        \n        As a concrete example, we see in Row 1 of Fig. 1 that the prompt “Vincent Van Gogh” produces a combination of both the artist themselves and images in their signature style. The former we think of as the “object” associated with the text prompt, and the latter as the visual styles associated with the prompt. We see precisely these two visual components removed when projecting onto the orthogonal complements of the two subspaces in turn. We hope this further clarifies the role of the subspaces.\n\n\n- `In the qualitative examples (Figure 5), the images also change and the semantics on removing one POS subspace do not guarantee that the original image's style is preserved.` **+ Question 2:** `Are there insights into persevering the underlying style of the image generated from the prompt?`\n\n\n    * In Fig. 5, our *goal* is to remove the visual styles associated with the text prompt, and thus the experiments support the claims as intended. We assume the reviewer intended to refer to Fig. 3 (and is asking why we get slightly different images after subspace projection):\n\n        Whilst we don’t claim to address local image editing nor preservation of the original image’s structure, we understand this to be a common phenomenon with TIIMs. For example, [1] states that: `\"In particular, even the slightest change in the textual prompt may lead to a completely different output image\"` (talking of the SOTA TTIMs). So we view this tendency not as a limitation introduced by the proposed method, but rather one we would inherit if using the method for image editing. If one’s goal was to preserve the image's original structure, incorporating ideas from [1] in freezing a subset of the cross-attention maps would be a sensible approach. We thank the reviewer for pointing this out, and we will add a discussion of this to our limitations section.\n        \n        - **[1]:** Hertz, Amir et al. “Prompt-to-Prompt Image Editing with Cross Attention Control.” *ICLR 2023.*\n\n\n- `It would be good to show the results [...] to show if the method actually works or just picks up on the partial prompts which would also work with the baseline model. For example, \"A mutlicolored Penguin\" and \"A penguin\" [...] can have similar results without the subspace projection.*` **+ Question 1**\n\n\n    * We politely draw attention to the fact that we already experiment with many examples of text prompts that are *not* decomposable into substrings  (e.g. Figs. 1&3 of the main paper and Fig. 1 of the supplementary material), which support the claim that the method works as intended in separating the latent associations of appearance and content.\n\n\n        As the reviewer correctly points out, however, in some simple descriptive example prompts (such as “a photo of a multicoloured penguin”) it is possible to manually break the prompt down into sub-prompts that describe each target component. We show in **Fig. 2 of the new rebuttal PDF** the outputs when doing this for the requested prompt. Such special cases of prompts can be seen to have a kind of “ground truth”, and thus we suggest that such comparison further validates that our method successfully produces the expected outcome in separating the two visual components.\n    \n        It’s important to note however that such **manual prompt engineering does not constitute a replacement to the proposed method**: for example, for the “style-blocking” tasks of Sect. 3.1.2, it is not possible to manually intervene at the text-prompt level given a user has unconstrained natural language control over the input text description. The same holds true of any other task with user-specified text input, or when the input is an image (e.g. in style- or content-based image retrieval).\n\n\n- `Disentanglement\" in multimodal approaches has been presented in prior work [1,2].`\n    \n    * We thank the reviewer for bringing these two works to our attention. Whilst both works focus on the task of image captioning, which is unrelated and outside the scope of the paper, we will be sure to discuss how both relate to the proposed method in the revised manuscript.\n\n\n        Briefly: [1]’s motivation is to produce “multiple, diverse captions that still properly describe the image”. This is similar in spirit to one problem with CLIP motivating our paper, in that there are multiple equally valid labels associated with an image. However, [1] focus solely on the task of image captioning, proposing a standalone method involving training a new series of networks for this specific task. [2] also proposes a new series of networks for the task of image captioning—attempting instead to disentangle the “object” in an image from the context in which it appears (as opposed to separating style from content, or using PoS)."}, {"review_id": "jCnFrEOHIR", "reviewer": "Reviewer_QWgZ", "summary": "The following work proposes a geometry-aware approach to identifying subspace projections within the CLIP embedding space. The projections allow one to limit the CLIP embeddings to the subspaces corresponding to individual parts of speech (noun, adj... ). This allows for more fine-grained controllability when using CLIP embeddings for downstream tasks such as text to image synthesis. Notably, the authors take into account the non-euclidean nature of CLIP embeddings (located on the surface of a hypersphere) by mapping it a specific tangent space first. Experiments demonstrate additional controllability with regards to visual style when given access to a part-of-speech partitioning of the CLIP embedding space.\n\n", "questions": "See weaknesses.", "limitations": "Adequately addressed.", "rating": 7, "confidence": 4, "soundness": 4, "presentation": 4, "contribution": 4, "strengths": "- Principled approach to handling the non-euclidean nature of the CLIP embedding space. Personally I think this is an important topic that is often overlooked in many applied works building on top of CLIP and the recent improved VQGAN architecture, both of which employ a normalized embedding space. While the geometry-aware formulation is perhaps not the most novel contribution of this work, I believe it may serve as an important blueprint for future works relying on normalized embeddings.\n- Overall, the closed-form linear formulation of the subspace solving objective provides a low complexity but effective solution to the problem statement.", "weaknesses": "- As much as the geometry aware formulation is mathematically justified, it would be nice to see some sort of experiment that demonstrates a significant loss in downstream task performance or even a simple plot based analysis as in the supplementary if one were to ignore it.\n- The visualization for lambda selection in supplementary figure 11 is unclear. The plotting software clearly overlays each point cloud on top of the others. As such, it is difficult to visually confirm the spread of all the point clouds except for the last one rendered, which I believe is the yellow adverb cloud. In order to properly visualize this, I think we would have to have juxtaposed separate plots for each cloud with the same axis scaling and offset.\n- While I am aware that there are many standards for placement of related works, I think it would be best for an earlier placement before methods given the proposed formulation's close relationship to fisher discriminant analysis.", "quality": null, "clarity": null, "significance": null, "originality": null, "strengths_and_weaknesses": "", "was_revised": false, "final_justification": "", "rebuttal": "We thank the reviewer for their praise of the paper and thorough review. We address the 3 stated weaknesses below:\n\n\n- `it would be nice to see some sort of experiment that demonstrates a significant loss in downstream task performance or even a simple plot based analysis as in the supplementary if one were to ignore it.`\n\n\n    * We kindly draw the reviewer’s attention to Fig. 8 in the supplementary material where we show that the submanifolds lead to higher downstream zero-shot accuracy than the Euclidean subspaces across almost all datasets considered. We highlight that this leads to gains of e.g. ~30% on flowers102 and almost 20% on CIFAR100 (which are non-trivial in the zero-shot setting).\n\n\n        We will make sure to include these results in the main paper with the extra page in the camera-ready version to emphasise these results.\n\n- `In order to properly visualize this, I think we would have to have juxtaposed separate plots for each cloud with the same axis scaling and offset.` \n\n\n    * We thank the reviewer for the helpful suggestion to separate the PoS point clouds within each subplot of Fig. 11 of the supplementary material to better visualise the relative spread—which would indeed be more intuitive.\n\n\n        Our only concern with this suggestion is that this would either lead to Figs. 11&12 spanning 8 pages (if we were to create 4 subplots for each current subplot) or make the figure much more cluttered and thus difficult for the reader to easily compare across values of lambda (if we instead subdivided each existing subplot into quadrants). We will endeavour to incorporate this latter subplot division suggestion and/or explore additional ways of better visualising this for the camera-ready, such as using an opacity < 1.0 for the existing plots to allow one to better view the other PoS point clouds underneath that of the adverb.\n\n- `I think it would be best for an earlier placement before methods given the proposed formulation's close relationship to fisher discriminant analysis.`\n\n\n    * We agree with the reviewer that, all else equal, placing the related work much earlier would be preferred. The reason we eventually opted to place the related work after the methodology section is to be able to contrast the proposed objective more precisely with the related existing methods, having previously introduced the paper’s notation and proposed mathematical formulation. For example, in this position, we can discuss exactly how each $\\mathbf{X}_i$ is manipulated by the different methods (the reader better understanding at this point what each matrix refers to in the context of the paper), and reference the equations describing the exact proposed formulation. We found this to be too confusing when the section was placed before the methodology.\n\n\n        Given the close relationship of the component analyses, however, we will add an additional brief, more high-level discussion about the connections to the related work in the introduction, given the extra page allowed in any final version of the paper—we thank the reviewer for the helpful suggestion.\n"}, {"review_id": "yuj7XxtFF3", "reviewer": "Reviewer_Qiru", "summary": "The paper gives a closed-form solution to project CLIP representation of image/text into a subspace with disentangled modes. The proposed method is demonstrated qualitatively in text-to-image generation, and quantitatively by zero-shot classification.", "questions": "N/A", "limitations": "The limitation is discussed, but only for the dimensionality of sub-space (a hyper-parameter k), which is superficial. ", "rating": 5, "confidence": 2, "soundness": 2, "presentation": 2, "contribution": 2, "strengths": "- The subspace projection proposed by the paper with a closed-form solution can directly be applied to models based on CLIP, without further training. \n- Qualitative results demonstrate the effectiveness in some extent.", "weaknesses": "- The motivation of this work is CLIP's representation is biased and unpredictable. The paper proposes to learn sub-space representations for content and appearance. There are many diffusion-based works on guided generation for controlling contents and appearances. However, the paper (claims to have wide applications in generation tasks) fails to compare to any current work on this topic.\n- Limited quantitative studies, except for zero-shot classification. \n\nIn summary, the close-form projection proposed in this paper is simple/fast and (qualitatively) effective in the some examples shown. But the paper lacks comparisons to recent works on diffusion generation with controllable contents and appearances. ", "quality": null, "clarity": null, "significance": null, "originality": null, "strengths_and_weaknesses": "", "was_revised": false, "final_justification": "", "rebuttal": "We thank the reviewer for their praise of the method as simple, fast, and effective. We address the two weaknesses raised below (where [LX] refers to line number X of the submitted paper):\n\n\n- `However, the paper (claims to have wide applications in generation tasks) fails to compare to any current work on this topic. [...] paper lacks comparisons to recent works on diffusion generation with controllable contents and appearances`\n\n\n    * We kindly highlight to the reviewer that **this work is focused on grounding vision-language representations in PoS****, with** **the** **applications mentioned above** **used** **specifically to evaluate said representations.**  Therefore, we respectfully disagree that a comparison to the controllable content/appearance image generation literature is appropriate for evaluating the claims we make in the paper about the PoS subspaces. In more detail, the goal of the paper is to recover the appropriate PoS subspaces that can provide more fine-grained control over the modes of variation in CLIP representations (e.g. [L48]). We *evaluate* this claim qualitatively with TTIMs and quantitatively through class invariance metrics and ZS classification. We expand below on how this pertains to each experiment:\n\n\n        **Visualising the CLIP representations (Fig. 3)**\n\n\n        - As we state throughout the paper (e.g. lines [L18,L190]), the style/content experiments in Fig. 3 serve simply as a **means of validating the learnt CLIP representations** qualitatively. This evaluation protocol follows that of the related works [1, 2] exploring CLIP representations, which both use text-to-image models for the same visualisation purpose but do not compare to image synthesis methods/techniques themselves for the same reasons we outline here.\n\n\n            For example, Reviewer-yh2S highlights that the `experimental results provide compelling evidence that the proposed approach effectively disentangles properties related to different parts of speech within the embedding space`, which is the intention of the qualitative text-to-image experiments in Fig. 3.\n\n\n        **Theme erasing (Figs. 4&5)**\n    \n        - The custom theme CLIP subspaces of Sect. 3.1.2 are further evaluated qualitatively in Figs. 4&5 with the theme erasing application. As discussed in the supplementary material, there are two related preprints to first appear on arXiv ~2 months before the submission deadline [3, 4] (we thus consider these “concurrent works” per the NeurIPS guidelines). However, both of these preprints work with specific submodules of the alternative stable diffusion TTIM, therefore there is no straightforward way to adapt the approaches to the CLIP-based Paella model nor to erase concepts from the CLIP feature space for comparison to the proposed method.\n\n\n        Finally, the reviewer quotes [L336] from our “limitations” sections, where we state that: `Whilst the model has wide application for both generative and discriminative tasks, it is not able to perfectly separate the modes of variation for every possible image and text prompt`. We have accordingly changed this to read: `Although the recovered subspaces show wide applicability in downstream tasks, [...]` to better reflect the scope of the paper.\n    \n- `Limited quantitative studies, except for zero-shot classification.`\n    \n    * We kindly draw the reviewer’s attention to the fact that zero-shot classification is *not* just the only way we evaluate the method quantitatively. A quantitative “class invariance” score is presented for two different applications in both Fig. 6 of the main paper and Fig. 6 of the supplementary material to further demonstrate that the subspaces capture variation in just the specific categories of words of interest.\n    \n----------\n\n**[1]:** Materzynska, Joanna et al. “Disentangling visual and written concepts in CLIP.” *(CVPR)* (2022).\n\n**[2]:** Menon, Sachit et al. “Task Bias in Vision-Language Models.” *ArXiv* abs/2212.04412 (2022).\n\n**[3]:** Gandikota, Rohit et al. “Erasing Concepts from Diffusion Models.” *ArXiv* abs/2303.07345 (Mar 2023).\n\n**[4]**: Kumari, Nupur et al. “Ablating Concepts in Text-to-Image Diffusion Models.” *ArXiv* abs/2303.13516 (Mar 2023).\n"}, {"review_id": "54PooQ6Kk9", "reviewer": "Reviewer_yh2S", "summary": "The paper presents an innovative solution to address the problem of polysemy within CLIP's embedding space. The authors propose a novel approach that involves decomposing CLIP embeddings into distinct subspaces, with each subspace representing a specific part of speech. This decomposition technique enables the isolation of different parts of speech within a given sentence, thereby facilitating subsequent manipulation in downstream tasks. The experimental results presented in the paper demonstrate the efficacy of the proposed approach in effectively eliminating properties associated with particular parts of speech during CLIP's text-to-image generation process.", "questions": "In the context of addressing polysemy and disambiguation, would it be more straightforward to incorporate more detailed descriptions in the prompts? Could you please elaborate on the advantages of the proposed method over using prompts with additional details?", "limitations": "Yes", "rating": 7, "confidence": 5, "soundness": 4, "presentation": 4, "contribution": 3, "strengths": "The paper presents a novel approach to decompose the embedding space of CLIP. Theoretical analysis and experimental results provide compelling evidence that the proposed approach effectively disentangles properties related to different parts of speech within the embedding space. This work is of significant value to researchers, as comprehending and manipulating the embedding space learned by deep neural networks is both crucial and challenging. Understanding the features that embeddings can represent and learning how to manipulate them is essential to the improvement of DNNs. The paper is written clearly and is well-structured.", "weaknesses": "While the paper's exploration of subspace decomposition focuses on addressing the polysemy issues associated with part of speech in CLIP embeddings, it is important to note that there are instances of polysemy that cannot be disambiguated solely based on part of speech. For example, consider the word \"crane,\" which can refer to both a bird and a machine. These instances present case-by-case ambiguities, and it remains unclear whether the proposed method can be extended to tackle such scenarios successfully as there are no universal subspaces that can disentangle all of them.", "quality": null, "clarity": null, "significance": null, "originality": null, "strengths_and_weaknesses": "", "was_revised": false, "final_justification": "", "rebuttal": "We thank the reviewer for the praise of the paper! We address all comments and questions raised in the two sections below:\n\n\n- `it is important to note that there are instances of polysemy that cannot be disambiguated solely based on part of speech. […] it remains unclear whether the proposed method can be extended to tackle such scenarios successfully as there are no universal subspaces that can disentangle all of them.`\n\n\n    * Please see **Fig. 1 of the new rebuttal PDF**, where we show our method can indeed be extended using the idea proposed in the paper of more specific visual subspaces to handle the reviewer’s example of a polysemous noun.\n\n\n        In particular, we show one can learn a custom “animal” subspace following the same protocol in Sect. 3.1.2 of the main paper. When projecting CLIP representations of “a photo of a crane” onto this subspace, we produce animals of the *bird*, rather than of machinery. Conversely, projecting the CLIP representation of “A photo of a bass” onto this subspace’s orthogonal complement *removes* the representation of “bass” as a fish, synthesizing instead just images of bass *guitars*, following the examples in [1]. We hope this provides further indication of the proposed method and the main objective’s value.\n    \n        We thank the reviewer for making the insightful comment that the parts of speech alone cannot disambiguate between certain instances of polysemy—we will address this in the paper’s limitations sections and include these new results clarifying the further potential of the custom visual subspaces. \n\n\n    \n- `In the context of addressing polysemy and disambiguation, would it be more straightforward to incorporate more detailed descriptions in the prompts? Could you please elaborate on the advantages of the proposed method over using prompts with additional details?`\n\n\n    * Whilst such manual prompt engineering requires additional effort relative to the automated subspace projections, and domain-specific understanding of each dataset (in the case of zero-shot learning for example), there are also more fundamental advantages to working on the CLIP representations directly.\n    \n        In particular, the ability to simply manually add additional details to the input prompts is not possible for tasks where it is a *user* with unconstrained natural language control over the input prompt. In such scenarios, it’s therefore necessary to perform the filtering/disambiguation on a later representation level such as with the proposed method. One example of this is the task of blocking stylistic imitation of Sect. 3.1.2, or when preventing the synthesis of e.g. gory imagery. \n    \n        Additionally, we highlight that we learn subspaces on the joint vision-language embeddings, allowing the method to also be applied to *image* representations--which do not permit the option to add additional text details to disambiguate/add desired context (for example, it’s the image representations that are projected onto the subspaces in the ZS experiments in section 3.2.2). This means the subspaces would also be applicable to tasks where the sole input is an image, such as CLIP-based image retrieval (e.g. to search based on either style or content similarity only, or to block the matching on NSFW imagery).\n\n    --- \n\n    **[1]:** Chefer, Hila et al. “The Hidden Language of Diffusion Models.” *ArXiv* abs/2306.00966 (2023).\n"}]

Author rebuttal:
We thank all four reviewers for their thorough comments and positive assessment of the paper:


- `Reviewer-3FWH` states that the work is “clearly motivated” and the method “easy to implement”.
- `Reviewer-QWgZ` praises the “principled approach to handling the non-euclidean nature of the CLIP embedding space“ that “may serve as an important blueprint for future work”.
- `Reviewer-Qiru` highlights the simplicity, speed, and effectiveness of the method for some of the qualitative results.
- `Reviewer-yh2S` notes the “work is of significant value to researchers”, and that the experiments and theoretical evidence provide “compelling evidence” of the proposed approach’s ability to disentangle properties relating to the PoS.

In our initial response, we have addressed all weaknesses raised and questions asked by the reviewers, which we hope clarifies any confusion or concerns. We encourage all reviewers to view the **additional 1-page PDF** containing two new figures. **Fig. 1** clarifies the method’s ability to disambiguate between additional instances of polysemy (e.g. “crane”) with the custom subspaces in reply to `Reviewer-yh2S`. **Fig. 2** compares when one synthesises images from sub-prompts describing the individual modes of variation. This further confirms the method works as expected when we have something close to a “ground truth” available for what the disentanglement should look like (as requested by `Reviewer-3FWH`). We are grateful to all reviewers for their time and helpful ideas and we believe the paper will be even stronger after incorporating their comments into any final version.


Meta-review: The paper has received mostly positive scores. The paper aims to disentangle concepts in the latent space of CLIP and experiments are provided especially for part-of-speech disentanglement. The reviewers recognize the usefulness and effectiveness of the method which was also demonstrated through qualitative results through synthesis. The reviewers also appreciate the generality of the proposed method beyond the applications demonstrated in this work. Particularly, preventing a method from copying an artists' style seems in text-to-image models is an important application highlighted by the authors. Overall the paper has a good motivation, methodology and experiments and is recommended for acceptance.
Decision: Accept (poster)