# Mask Mixup Model: Enhanced Contrastive Learning for Few-Shot Learning
## 1 Introduction  
Conventional neural image classifiers have demonstrated exceptional performance across diverse setups and benchmarks. However, they still heavily rely on abundant labeled training data. Most significantly, these methods struggle to adapt learned knowledge to target categories. Inspired by humans' ability for few-shot learning, the concept of few-shot image classification has been proposed. It aims to identify target categories by adjusting the knowledge learned previously from source categories. This knowledge is typically stored within a deep embedding model, utilized for supporting and querying generic matches of image pairs. A promising approach involves leveraging meta-learning frameworks to optimize the initialization of model parameters [1; 2; 3] or replace standard parameter linear classifier heads [4; 5; 6] with class-agnostic distance functions. Although these methods have shown significant performance, the key challenge of few-shot image classification still lies in eliminating the inductive bias problem from source classes to tailor its preference for hypotheses according to the few training instances from new target classes. On the other hand, it could lead to getting a flawed embedding due tothe inadequacy of one or just a few instances in effectively capturing the data distributions pertaining to the novel classes. To address these issues, refs. [7; 8; 9] introduce variations in the training data to encourage the model to learn a more general and adaptive representation. Furthermore, augmenting the learned embeddings with data variety forces the model to acquire more comprehensive and discriminative embeddings. However, as depicted in the left images of Figure 1a, The outcomes generated from randomly obscured samples might either fully expose or entirely obscure crucial regions. This circumstance might hamper the model's acquisition of new features or impact its capacity to discriminate among distinct categories and effectively generalize. Illustrated in the right images of Figure 1a, these approaches only consider mixing a given random pair of input data and do not fully utilize the rich informative supervisory signal in training data. To address these challenges in few-shot learning, this paper introduces three modules: (1) Mask Mix (M-Mix), (2) Saliency Fuse (SF), and (3) Confident Clip Selector (CCS). The M-Mix module masks the images guided by the saliency map and then blends them, as shown in the upper image of Figure 1b, producing images that are more representative and contain richer information. Humans can identify objects by seeing only a part of them, and these images mimic this scenario, enabling models to acquire such abilities which allows models to learn better embeddings. To get closer to realizing a half-obscured scene, we pass the query through the CCS module, making it only part of the object as well. On the other hand, the SF module systematically examines the mix-matching of distinct salient regions across all input data, ensuring that each produced mixup example incorporates a maximum number of salient regions from diverse input sources. This process is conducted with the careful consideration of maintaining diversity among the resulting mixup examples. The main contributions of this paper are as follows:  
1. We have introduced a novel approach called M-Mix, designed to generate positive and negative samples for contrastive learning. By applying masks and merging images, this method enables the model to recognize object categories based on parts of objects, reducing erroneous pixel correlations, and enhancing the model's generalization capabilities. Figure 1: (**a**) represents prior work. (**b**) showcases images generated by our M-Mix method and SF method. 2. The CCS method we proposed has enabled us to generate a larger quantity of higher-quality query instances. This increase in training sample diversity aids the model in better coping with noise, generalizing to unknown data, and improving overall performance. 3.