📝 Abstract:
Real-world data is often long-tailed. Most of the training samples belong to common classes, while rare classes have limited samples. Models trained on long-tailed data with standard loss functions like cross entropy become biased towards common classes and perform poorly on rare classes. The loss functions proposed for this problem are point-based: the loss of a sample depends only on the model's prediction for that sample, and the total loss is an average over samples. Therefore, common classes dominate the average. In contrast, in a ranking-based loss, the loss of a sample is computed from the position of its positive logit score among all other logit scores. This family has been used successfully in domains such as object detection; however, its application to long-tailed recognition has not been studied sufficiently. This thesis fills this gap. We make the Average Precision (AP) loss macro-averaged, so that every class receives a balanced share of the total loss. We also make the steepness parameter of the sigmoid function used in ranking-based losses learnable, with a separate parameter for each class. We prove that the proposed loss has desired theoretical properties such as Lipschitz continuity, convexity, and balanced gradients between and within classes. The loss function is plug-and-play: it does not require changes to the model architecture or the data sampling.