<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta>
      <journal-title-group>
        <journal-title>V. O. Yenumulapalli);
rajalakshmis@ssn.edu.in (R. Sivanaiah); angeldeborahs@ssn.edu.in (A. D. Suseelan)</journal-title>
      </journal-title-group>
    </journal-meta>
    <article-meta>
      <title-group>
        <article-title>Optimizing Visual Pairings: A CLIP Framework for Precision News Image Rematching</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Pooja Premnath</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Venkatasai Ojus Yenumulapalli</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Rajalakshmi Sivanaiah</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Angel Deborah Suseelan</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Department of Computer Science and Engineering, Sri Sivasubramaniya Nadar College of Engineering</institution>
          ,
          <addr-line>Chennai - 603110, Tamil Nadu</addr-line>
          ,
          <country country="IN">India</country>
        </aff>
      </contrib-group>
      <pub-date>
        <year>2023</year>
      </pub-date>
      <volume>000</volume>
      <fpage>0</fpage>
      <lpage>0001</lpage>
      <abstract>
        <p>The primary aim of the MediaEval 2023 NewsImages task is to augment the understanding of the interplay between textual and visual elements in news articles. This involves the precise alignment of textual information with its corresponding visual counterpart. News articles leverage a combination of text and images to convey information and engage readers in a multimedia format. The variety of online news articles, coupled with the complexity of the relationship between textual content and images, poses a unique challenge. The proposed approach leverages CLIP's capabilities, employing separate encoders for text (DistilBERT) and images (ResNet50), and projecting embeddings into a lower-dimensional space. The key insight emerged from efectively using the CLIP model to establish a smooth correlation between textual narratives and images. Trained on the NewsImages 2023 dataset, encompassing both real and generated images, the model's results are evaluated using the Mean Reciprocal Rank (MRR) and Precision@K metrics.</p>
      </abstract>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1. Introduction</title>
      <p>
        The dynamic nature of internet news items showcases a complex interplay between written
material and other multimedia components, including visuals. In contrast to domains like picture
captioning, where captions convey content that is presented directly, the relationship between
text and images in news articles is much more complex. The wide spectrum of news topics,
which includes politics, economics, sports, health, and entertainment, adds to this complexity.
The dificulty increases when timely visuals are unavailable and stock photos or even generated
images are used. The objective of this paper is to identify the intricate relationship between text
and images and match the corresponding news text-image pair, as called for by the NewsImages
2023 task [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ]. The approach to the task utilizes an implementation of Contrastive
LanguageImage Pretraining (CLIP), to accurately match corresponding news text-image pairs in diverse
and dynamic online contexts.
      </p>
    </sec>
    <sec id="sec-2">
      <title>2. Related Work</title>
      <p>
        Innovative approaches are required to understand and align textual and visual elements in
online articles for a more comprehensive news consumption experience. In recent research,
multi-modal news analysis, as explored by Cheema et al. [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ], addressed various factors within
journalism, such as the author’s intent and cross-modal relations. This work extends existing
comprehensive approaches to understanding news-centric attributes and user-subjective
interpretation. This approach provides a unique perspective on the problem, considering various
factors that contribute to a comprehensive understanding of existing solutions to the issue.
However, this paper shifts the focus to the CLIP model, utilizing its contrastive language-image
pre-training for semantic relation discovery between text and images. While Cheema et al. [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ]
concentrated on multi-modal news analysis, this research emphasizes the application of CLIP
in image-text relationships.
      </p>
      <p>
        For computer vision training, Radford et al. [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] proposed a novel approach using CLIP, training
pre-existing models on a vast dataset to predict image captions. In the context of news-image
re-matching, Cao et al. [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ] fine-tuned the CLIP model through translation, text processing, and
evaluation steps, showcasing its adaptability for news-related applications.
      </p>
      <p>
        On the topic of self-supervised learning, Wang et al. [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ] introduced CLIP-GEN, eliminating
the need for expensive matched text-image data to train a general text-to-image generator.
Liu et al. [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ] presented CMA-CLIP, a framework unifying sequence-wise and modality-wise
attention to leveraging both image and text modalities for improved performance in tasks such
as classification and recommendation.
      </p>
      <p>
        Shen et al. [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ] explored the integration of CLIP into existing models, highlighting its potential
for specific tasks beyond journalism, thus expanding the applications of pre-trained encoders.
Moving into image generation, Ramesh et al. [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ] engineered a two-stage model leveraging
the joint embedding space of CLIP, enabling zero-shot language-guided image manipulations,
demonstrating the potential for hierarchical image synthesis.
      </p>
      <p>
        Addressing the limitation of mismatching in image-text matching caused by CLIP’s global
feature contrasting, Peng et al. [
        <xref ref-type="bibr" rid="ref9">9</xref>
        ] introduced CIT, a novel approach that enhances image-text
matching accuracy by incorporating fine-grained inter-modal information, transforming CLIP
into a more eficient Image-Text Matching (ITM) model. The extensive research on CLIP suggests
its pivotal role as a model for addressing the problem statement. The model proposed by Radford
et al. [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] emerges as particularly suitable, ofering a foundational approach for fine-tuning the
model to predict images based on caption prompts.
      </p>
    </sec>
    <sec id="sec-3">
      <title>3. Approach</title>
      <p>
        To match clippings from news articles with the most appropriate image, the CLIP (Contrastive
Language-Image Pre-training) model is used. CLIP learns a shared embedding space for images
and their corresponding textual descriptions, fostering a unified understanding of multimodal
relationships. The contrastive learning framework enhances the model’s robustness by
maximizing the similarity of correct image-text pairs and minimizing the similarity of incorrect pairs.
CLIP’s capability for zero-shot learning is invaluable in scenarios with diverse and evolving
datasets, such as news articles with varying topics. The model built uses a structure similar to
that of Shariatnia [
        <xref ref-type="bibr" rid="ref10">10</xref>
        ]. The model is composed of three main sections—the image encoder, text
encoder, and a module for the projection of the embeddings.
      </p>
      <sec id="sec-3-1">
        <title>3.1. Image Encoder</title>
        <p>The image encoder model plays a critical role in the pre-training pipeline, in order to extract
meaningful features from input images. Deep convolutional layers are adopted to capture
hierarchical representations of the content. A pre-trained ResNet50 model is employed, to
enhance the encoder’s ability to discern patterns and features. A global average pooling, and a
zero-class classification configuration are utilized, to extract a fixed-size vector representation.</p>
      </sec>
      <sec id="sec-3-2">
        <title>3.2. Text Encoder</title>
        <p>The text encoder model makes use of DistilBERT. A tokenizer with a maximum sequence length
of 200 tokens is used. In the forward pass, the module takes in the input tokens and attention
masks, computes the last hidden state through the DistilBERT model and then the final sentence
embedding is derived by using the CLS token’s hidden representation from the last hidden state
tensor.</p>
      </sec>
      <sec id="sec-3-3">
        <title>3.3. Projection to a Lower Dimension</title>
        <p>The input embeddings are then projected into a 256-dimensional space. In the forward pass, a
linear projection layer, followed by a GELU activation function is used. This is followed by a
dropout layer and layer normalization. The CLIP model that is built receives a batch containing
image data and text inputs. The image and text features are encoded separately through the
respective encoders, and then the image and text embeddings are projected.</p>
      </sec>
      <sec id="sec-3-4">
        <title>3.4. Similarity between Image and Text Embeddings</title>
        <p>The similarity between the image and text embeddings is computed using the dot product. The
dot similarity serves as a measure of alignment between the two kinds of embeddings. It is
calculated by taking the dot product of the normalized embeddings, providing a scalar value
that signifies the degree of similarity between the two. When the vectors are perfectly aligned
with a cosine similarity of 1, it indicates a high degree of similarity between the news article
and the corresponding image. However, when the vectors are orthogonal in nature, the dot
product is minimal, signifying dissimilarity. The resulting similarity scores are adjusted with
the softmax function and utilized to calculate the contrastive loss. A cross entropy loss is also
calculated. The overall loss is calculated as the mean of the losses from the image and text
modalities, and backpropagation is executed accordingly. The CLIP model is trained with ten
epochs, using a batch size of 32, a projection dimension of 256 and a dropout rate of 0.1.</p>
      </sec>
    </sec>
    <sec id="sec-4">
      <title>4. Results and Analysis</title>
      <p>To assess the task’s performance, the Mean Reciprocal Rank was employed as the primary
metric, complemented by Precision@K scores (with K values of 1, 5, 10, 20, 50, 100). The Mean
Reciprocal Rank provides insight into the average position at which the linked image appears.
Achieving an early match contributes to a higher average score, and the precision scores at
various positions in the prediction list ofer a nuanced performance evaluation.</p>
      <p>Oxford researcher to watch Barbie as ’dessert’ to Oppenheimer amid dual premiere</p>
      <p>On the GDELT-P1 dataset, encompassing standard articles and their corresponding images,
the model demonstrated a Mean Reciprocal Rank of 0.07839. In practical terms, this signifies
that, on average, the model identifies the first correct match around the 13 th position in the
list of predictions for each query. Notably, its performance excelled on the GDELT-P2 dataset,
primarily comprising images generated by machine-learning models. Here, the model identified
the first correct match at around the 10 th position. The images presented in Figure 2 depict the
top three retrievals corresponding to the given prompt.</p>
    </sec>
    <sec id="sec-5">
      <title>5. Discussion and Outlook</title>
      <p>This work explores the performance of the CLIP model in the text-image matching task of
NewsImages at MediaEval 2023. A fair level of accuracy was obtained using CLIP, as evaluated
using the Mean Reciprocal Rank and the Precision@K scores. The model exhibits superior
performance on the GDELT-P2 dataset, with the generated images compared to the GDELT-P1
dataset. To expand the scope and enhance the eficacy of the model, a viable strategy involves
training the CLIP model with a language-specific text encoder. By incorporating
languagespecific features and nuances, this tailored approach aims to bolster the model’s understanding
and performance. Furthermore, to advance the contributions of this work, future endeavors
could concentrate on delving into the intricacies of the model and implementing additional
ifne-tuning techniques.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [1]
          <string-name>
            <given-names>A.</given-names>
            <surname>Lommatzsch</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            <surname>Kille</surname>
          </string-name>
          , Ö. Özgöbek,
          <string-name>
            <given-names>M.</given-names>
            <surname>Elahi</surname>
          </string-name>
          ,
          <string-name>
            <surname>D.-T.</surname>
          </string-name>
          Dang-Nguyen,
          <article-title>News images in mediaeval 2023</article-title>
          ,
          <source>in: Proceedings of the MediaEval Benchmarking Initiative</source>
          <year>2023</year>
          , CEU Workshop Proceedings,
          <year>2024</year>
          . URL: http://ceur-ws.org/.
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [2]
          <string-name>
            <given-names>G. S.</given-names>
            <surname>Cheema</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Hakimov</surname>
          </string-name>
          ,
          <string-name>
            <given-names>E.</given-names>
            <surname>Müller-Budack</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C.</given-names>
            <surname>Otto</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J. A.</given-names>
            <surname>Bateman</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Ewerth</surname>
          </string-name>
          ,
          <article-title>Understanding imagetext relations and news values for multimodal news analysis</article-title>
          ,
          <source>Frontiers in Artificial Intelligence</source>
          <volume>6</volume>
          (
          <year>2023</year>
          )
          <fpage>1125533</fpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [3]
          <string-name>
            <given-names>A.</given-names>
            <surname>Radford</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J. W.</given-names>
            <surname>Kim</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C.</given-names>
            <surname>Hallacy</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Ramesh</surname>
          </string-name>
          , G. Goh,
          <string-name>
            <given-names>S.</given-names>
            <surname>Agarwal</surname>
          </string-name>
          ,
          <string-name>
            <given-names>G.</given-names>
            <surname>Sastry</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Askell</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Mishkin</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Clark</surname>
          </string-name>
          ,
          <string-name>
            <given-names>G.</given-names>
            <surname>Krueger</surname>
          </string-name>
          ,
          <string-name>
            <surname>I. Sutskever</surname>
          </string-name>
          ,
          <article-title>Learning transferable visual models from natural language supervision</article-title>
          ,
          <source>in: International Conference on Machine Learning</source>
          ,
          <year>2021</year>
          . URL: https://api.semanticscholar. org/CorpusID:231591445.
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          [4]
          <string-name>
            <given-names>T.</given-names>
            <surname>Cao</surname>
          </string-name>
          ,
          <string-name>
            <given-names>N.</given-names>
            <surname>Ngô</surname>
          </string-name>
          , T.-D. Le,
          <string-name>
            <given-names>T.</given-names>
            <surname>Huynh</surname>
          </string-name>
          , N.-T. Nguyen,
          <string-name>
            <given-names>H.</given-names>
            <surname>Nguyen</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Tran</surname>
          </string-name>
          , Hcmus at mediaeval 2021:
          <article-title>Fine-tuning clip for automatic news-images re-matching</article-title>
          ,
          <source>in: Working Notes Proceedings of the MediaEval 2021 Workshop</source>
          , Online, volume
          <volume>3181</volume>
          ,
          <year>2021</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          [5]
          <string-name>
            <given-names>Z.</given-names>
            <surname>Wang</surname>
          </string-name>
          ,
          <string-name>
            <given-names>W.</given-names>
            <surname>Liu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Q.</given-names>
            <surname>He</surname>
          </string-name>
          ,
          <string-name>
            <given-names>X.</given-names>
            ru
            <surname>Wu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Z.</given-names>
            <surname>Yi</surname>
          </string-name>
          ,
          <article-title>Clip-gen: Language-free training of a text-to-image generator with clip</article-title>
          ,
          <source>ArXiv abs/2203</source>
          .00386 (
          <year>2022</year>
          ). URL: https://api.semanticscholar.org/CorpusID:247187508.
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          [6]
          <string-name>
            <given-names>H.</given-names>
            <surname>Liu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Xu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Fu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Y.</given-names>
            <surname>Liu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>N.</given-names>
            <surname>Xie</surname>
          </string-name>
          ,
          <string-name>
            <surname>C.-C. Wang</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          <string-name>
            <surname>Wang</surname>
            ,
            <given-names>Y.</given-names>
          </string-name>
          <string-name>
            <surname>Sun</surname>
          </string-name>
          , Cma-clip:
          <article-title>Cross-modality attention clip for image-text classification</article-title>
          ,
          <year>2021</year>
          . arXiv:
          <volume>2112</volume>
          .
          <fpage>03562</fpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          [7]
          <string-name>
            <given-names>S.</given-names>
            <surname>Shen</surname>
          </string-name>
          ,
          <string-name>
            <given-names>L. H.</given-names>
            <surname>Li</surname>
          </string-name>
          ,
          <string-name>
            <given-names>H.</given-names>
            <surname>Tan</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Bansal</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Rohrbach</surname>
          </string-name>
          ,
          <string-name>
            <given-names>K.-W.</given-names>
            <surname>Chang</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Z.</given-names>
            <surname>Yao</surname>
          </string-name>
          ,
          <string-name>
            <given-names>K.</given-names>
            <surname>Keutzer</surname>
          </string-name>
          ,
          <article-title>How much can CLIP benefit vision-and-language tasks?</article-title>
          ,
          <source>in: International Conference on Learning Representations</source>
          ,
          <year>2022</year>
          . URL: https://openreview.net/forum?id=zf_
          <fpage>Ll3HZWgy</fpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          [8]
          <string-name>
            <given-names>A.</given-names>
            <surname>Ramesh</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Dhariwal</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Nichol</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C.</given-names>
            <surname>Chu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Chen</surname>
          </string-name>
          ,
          <article-title>Hierarchical text-conditional image generation with clip latents</article-title>
          ,
          <source>ArXiv abs/2204</source>
          .06125 (
          <year>2022</year>
          ). URL: https://api.semanticscholar.org/CorpusID: 248097655.
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          [9]
          <string-name>
            <given-names>S.</given-names>
            <surname>Peng</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Y.</given-names>
            <surname>Bu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>Z.</given-names>
            <surname>Li</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Wang</surname>
          </string-name>
          ,
          <string-name>
            <given-names>T.</given-names>
            <surname>Yao</surname>
          </string-name>
          ,
          <article-title>Turning a clip modal into image-text matching</article-title>
          ,
          <source>in: 3rd International Conference on Artificial Intelligence</source>
          , Automation, and
          <article-title>High-Performance Computing (AIAHPC</article-title>
          <year>2023</year>
          ), volume
          <volume>12717</volume>
          ,
          <string-name>
            <surname>SPIE</surname>
          </string-name>
          ,
          <year>2023</year>
          , pp.
          <fpage>901</fpage>
          -
          <lpage>905</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          [10]
          <string-name>
            <surname>M. M. Shariatnia</surname>
          </string-name>
          ,
          <string-name>
            <surname>Simple</surname>
            <given-names>CLIP</given-names>
          </string-name>
          ,
          <year>2021</year>
          . doi:
          <volume>10</volume>
          .5281/zenodo.6845731.
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>