We used MiniGPT-4 for obtaining LMM-based knowledge using the prompts described in the paper. We used ViT-L-14 CLIP and LongCLIP-L for extracting the image and text embeddings for building the input meme representations. The feature representations, built using the proposed method, and the trained models for Harm-C and PrideMM datasets (using both the CLIP and LongCLIP models) can be downloaded using the link.
- Training
python3 train.py --weight 0.05 --k 1- Evaluation
python3 eval.py --weights_path /path/to/harmc_clip.pthEvaluation results of the proposed method in terms of test accuracy (%) (5 runs) on Harm-C and PrideMM.
| Method | Harm-C | PrideMM |
|---|---|---|
| LMM-CLIP | 86.33 | 76.31 |
| LMM-LongCLIP | 87.23 | 75.89 |
This code is provided for academic, non-commercial use only. Please also check for any restrictions applied in the code parts and datasets used here from other sources. For the materials not covered by any such restrictions, redistribution and use in source and binary forms, with or without modification, are permitted for academic non-commercial use provided that the following conditions are met:
Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation provided with the distribution.
This software is provided by the authors "as is" and any express or implied warranties, including, but not limited to, the implied warranties of merchantability and fitness for a particular purpose are disclaimed. In no event shall the authors be liable for any direct, indirect, incidental, special, exemplary, or consequential damages (including, but not limited to, procurement of substitute goods or services; loss of use, data, or profits; or business interruption) however caused and on any theory of liability, whether in contract, strict liability, or tort (including negligence or otherwise) arising in any way out of the use of this software, even if advised of the possibility of such damage.
If you find our method useful in your work or you use some materials provided in this repo, please cite the following publication where our method and materials were presented:
Pre-print: http://arxiv.org/abs/2504.09914
@inproceedings{tzelepi2025improving,
title={Improving multimodal hateful meme detection exploiting LMM-generated knowledge},
author={Tzelepi, Maria and Mezaris, Vasileios},
year={2025},
booktitle={Multimodal Learning and Applications (MULA) Workshop at IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) 2025}
}


