This repository contains the code for the paper "InfMasking: Unleashing Synergistic Information by Contrastive Multimodal Interactions"(NeurIPS 2025)🎉🎉🎉.
If you find this repository useful for your research, please consider citing us:
@inproceedings{wen2025infmasking,
title={InfMasking: Unleashing Synergistic Information by Contrastive Multimodal Interactions},
author={Liangjian Wen and Qun Dai and Jianzhuang Liu and Jiangtao Zheng and Yong Dai and Dongkai Wang and Zhao Kang and Jun Wang and Zenglin Xu and Jiang Duan},
booktitle={The Thirty-ninth Annual Conference on Neural Information Processing Systems},
year={2025}
}Abstract: In multimodal representation learning, synergistic interactions between modalities not only provide complementary information but also create unique outcomes through specific interaction patterns that no single modality could achieve alone. Existing methods may struggle to effectively capture the full spectrum of synergistic information, leading to suboptimal performance in tasks where such interactions are critical. This is particularly problematic because synergistic information constitutes the fundamental value proposition of multimodal representation. To address this challenge, we introduce InfMasking, a contrastive synergistic information extraction method designed to enhance synergistic information through an Infinite Masking strategy. InfMasking stochastically occludes most features from each modality during fusion, preserving only partial information to create representations with varied synergistic patterns. Unmasked fused representations are then aligned with masked ones through mutual information maximization to encode comprehensive synergistic information. This infinite masking strategy enables capturing richer interactions by exposing the model to diverse partial modality combinations during training. As computing mutual information estimates with infinite masking is computationally prohibitive, we derive an InfMasking loss to approximate this calculation. Through controlled experiments, we demonstrate that InfMasking effectively enhances synergistic information between modalities. In evaluations on large-scale real-world datasets, InfMasking achieves state-of-the-art performance across seven benchmarks.
Paper link: "InfMasking: Unleashing Synergistic Information by Contrastive Multimodal Interactions".
Please create a conda environment with python 3.8 and install the required packages after the code is cloned.
conda env create -f environment.yml
conda activate multimodal
cd InfMaskingTo run the synthetic experiments on Trifeature datasets, please execute the following command:
bash run_scripts/trifeatures_run.shTo evaluate the learned representations, please execute the following command. Please change the dataset and specific-dataset parameters in run_scripts/test.sh before running the command.
bash run_scripts/test.shThe evaluation of below models is supported in run_scripts/test.sh.
We select "Cross", "Cross+Self", FactorCL, MAE and CoMM as baselines for comparison. Linear probing accuracy (in %) of redundancy (shape), uniqueness (texture) and synergy (color and texture) on Trifeature dataset is shown in the table below.
| Model | redundancy↑ | uniqueness↑ | synergy↑ |
|---|---|---|---|
To run the experiments with 2 modalities on Multibench, please execute the following command:
bash run_scripts/multibench_run.shLinear probing MSE(
| Model | Regression V&TEE↓ |
MIMIC↑ | MOSI↑ | UR-FUNNY↑ | MUSTARD↑ | Classification Average* ↑ |
|---|---|---|---|---|---|---|
To run the experiments with 3 modalities on Multibench, please execute the following command:
bash run_scripts/all-mod_run.shLinear probing top-1 accuracy (in %) for classification tasks on Vision&Touch and UR-FUNNY datasets with 3 modalities on Multibench is shown in the table below.
| Model | #Mod. | V&T CP↑ | UR-FUNNY↑ |
|---|---|---|---|
| 2 | |||
| 2 | |||
| 2 | |||
| 2 | |||
| 3 | |||
| 3 | |||
| 3 |
To run the experiments with 2 modalities on Multimodal IMDb, please execute the following command:
bash run_scripts/MM_IMDb_run.shLinear probing F1-score (weighted and macro) (in %) for MM-IMDB is shown in the table below.
| Model | Modalities | weighted-f1↑ | macro-f1↑ |
|---|---|---|---|
| V | |||
| V | |||
| L | |||
| V+L | |||
| V+L | |||
| V+L | |||
| V+L | |||
| V+L |
We sincerely thank the contributors of the following repositories, which have been instrumental in our implementation:
