Improving memory banks for unsupervised learning with large mini-batch, consistency and hard negative mining
This work provides substantial improvements to unsupervised learning using memory banks, which is relevant for researchers and practitioners working on self-supervised representation learning.
This paper introduces three improvements to memory bank-based unsupervised learning: large mini-batches with multiple augmentations, consistency enforcement for same-sample augmentations, and hard negative mining to merge visually similar samples. These enhancements significantly improve the vanilla memory bank approach and surpass existing methods on both seen and unseen testing categories.
An important component of unsupervised learning by instance-based discrimination is a memory bank for storing a feature representation for each training sample in the dataset. In this paper, we introduce 3 improvements to the vanilla memory bank-based formulation which brings massive accuracy gains: (a) Large mini-batch: we pull multiple augmentations for each sample within the same batch and show that this leads to better models and enhanced memory bank updates. (b) Consistency: we enforce the logits obtained by different augmentations of the same sample to be close without trying to enforce discrimination with respect to negative samples as proposed by previous approaches. (c) Hard negative mining: since instance discrimination is not meaningful for samples that are too visually similar, we devise a novel nearest neighbour approach for improving the memory bank that gradually merges extremely similar data samples that were previously forced to be apart by the instance level classification loss. Overall, our approach greatly improves the vanilla memory-bank based instance discrimination and outperforms all existing methods for both seen and unseen testing categories with cosine similarity.