Skip to content
TomorrowJWPublic

About

This work has been accepted by AAAI2026 Main Track.

Resources

Stars

7 stars

Watchers

0 watching

Forks

Repository files navigation

SPP-SCL: Semi-Push-Pull Supervised Contrastive Learning for Image-Text Sentiment Analysis and Beyond

AAAI Conference on Artificial Intelligence (AAAI), 2026

Authors:
Jiesheng Wu¹, Shengrong Li² (Corresponding author) ¹ School of Computer and Information, Anhui Normal University, Wuhu, China ² College of Artificial Intelligence, Nanjing University of Aeronautics and Astronautics, Nanjing, China

1. Preface

  • This repository provides codes for "SPP-SCL: Semi-Push-Pull Supervised Contrastive Learning for Image-Text Sentiment Analysis and Beyond" AAAI 2026. Paper

2. Overview

2.1. Introduction

Existing Image-Text Sentiment Analysis (ITSA) methods may suffer from inconsistent intra-modal and inter-modal sentiment relationships. Therefore, we develop a method that balances before fusing to solve the issue of vision-language imbalance intra-modal and inter-modal sentiment relationships; that is, a Semi-Push-Pull Supervised Contrastive Learning (SPP-SCL) method is proposed. Specifically, the method is implemented using a novel two-step strategy, namely first using the proposed intra-modal supervised contrastive learning to pull the relationships between the intra-modal and then performing a well-designed conditional execution statement. If the statement result is false, our method will perform the second step, which is inter-modal supervised contrastive learning to push away the relationships between inter-modal. The two-step strategy will balance the intra-modal and inter-modal relationships to achieve the purpose of relationship consistency and finally perform cross-modal feature fusion for sentiment analysis and detection. Experimental studies on three public image-text sentiment and sarcasm detection datasets demonstrate that SPP-SCL significantly outperforms state-of-the-art methods by a large margin and is more discriminative in sentiment.

2.2. Framework Overview


Figure 1: Overall architecture of SPP-SCL. The framework includes two main steps: intra-modal sentiment alignment via supervised contrastive learning, and conditional inter-modal sentiment alignment.

2.3. Quantitative Results


Figure 2: Quantitative Results

2.4. Qualitative Results


Figure 3: Qualitative Results.

3. Proposed Method

3.1. Training/Testing

The training and testing experiments are conducted using PyTorch with an NVIDIA Tesla V100 GPU of 16 GB Memory.

  1. Configuring your environment (Prerequisites):

    • Installing necessary packages: pip install -r requirements.txt.
    • Our training, validation, and testing partitioning follows the CLMLF partitioning method in NAACL2022 to ensure fair comparison.
  2. Downloading necessary data:

    • downloading the datasets and moving them into ./data/, which can be found from two MVSA Datasets for MVSA-Single and MVSA-Multiple Datasets. HFM Dataset can be found from HFM. Also, these datasets can be downloaded from our (Baidu Drive) (extraction code:5iew).

    • downloading our weights and move them into ./save_models/MVSA-S.pth or MVSA-M.pth or HFM.pth, which can be found from (Baidu Drive) (extraction code: afr5).

    • downloading pre-trained ResNet50 and bert-base-uncased weights and move them into ./pre_train/ and ./bert-base-uncased/, which can be found from Baidu Drive (extraction code: dgp6) and Baidu Drive (extraction code: ys4w).

  3. Training Configuration:

    • After you download the dataset, just run train.py to train our model.
  4. Testing and Evaluating Configuration:

    • After you download all the trained weights, just run test.py to perform a prediction.
    • 📢 Important Update: Due to accidental server cleanup, all models were retrained on new hardware. The updated results (see results.txt) are even better than those reported in the AAAI 2026 paper.

Note: If you have difficulty accessing Baidu Drive, please contact us for alternative download links.

4. Citation

Please cite our paper if you find the work useful. Thanks!

@article{Wu_Li_2026,
	title={SPP-SCL: Semi-Push-Pull Supervised Contrastive Learning for Image-Text Sentiment Analysis and Beyond},
	volume={40},
	url={https://ojs.aaai.org/index.php/AAAI/article/view/37200},
	DOI={10.1609/aaai.v40i3.37200},
	number={3}, 
	journal={Proceedings of the AAAI Conference on Artificial Intelligence},
	author={Wu, Jiesheng and Li, Shengrong}, 
	year={2026},
	month={Mar.}, 
	pages={2173-2181}
	}

5. Contact

For any questions, discussions, or collaboration opportunities, please contact:

Jiesheng Wu
School of Computer and Information, Anhui Normal University, Wuhu, China Email: jasonwu@mail.nankai.edu.cn

⬆ back to top

About

This work has been accepted by AAAI2026 Main Track.

Resources

Stars

7 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages