Git Product home page Git Product logo

gclloss's Introduction

GCL: Long-tailed Visual Recognition via Gaussian Clouded Logit Adjustment

This is the source code for our CVPR (2022) paper: Long-tailed Visual Recognition via Gaussian Clouded Logit Adjustment based on Pytorch. This version is a demo of how to use GCL loss. The version that supports more datasets is in the works and is coming soon.

CIFAR10

First stage

$ python cifar_train_backbone.py --arch resnet32 /
                                 --dataset cifar10 --data_path './dataset/data_img' /
                                 --loss_type 'GCL' --imb_factor 0.01 /
                                 --batch_size 64 --learning_rate 0.1 

Second stage

$ python cifar_train_classifier.py --arch resnet32 /
                                 --dataset cifar10 --data_path './dataset/data_img' /
                                 --loss_type 'GCL' --imb_factor 0.01 /
                                 --train_rule 'BalancedRS'/
                                 --batch_size 64 --learning_rate 0.1 

Results and Models for Large-scale Datasets (temporarily)

*Note: I have modified the code several times. The code in this repository may need to be modified (Mainly the backbone and classifier loading parts, the classifier network layer names may be inconsistent.) to match the pth file. Since I left my previous workplace, there is no GPU retraining model now. I temporarily share previously stored pth file for the model. Sorry for the inconvience and hope you can understand.

  • Stage-1:
Dataset Arch Top-1 Accuracy Log Model
ImageNet-LT ResNet-50 52.928% link link
iNat 2018 ResNet-50 70.327% link link
Places-LT ResNet-152 34.589% link link
  • Stage-2:
Dataset Arch Top-1 Accuracy Log Model
ImageNet-LT ResNet-50 54.884% link (train) link (val) link
iNat 2018 ResNet-50 72.005% link link
Places-LT ResNet-152 40.641% link link

Citation

To do list:

  • Support Cifar10/100-LT dataset
  • Support imageNet-LT
  • Support iNaturalist2018
  • Support Places365-LT
  • More loss functions
  • Separate configuration files for easier execution
  • Some other minor performance improvements

Other Resources of long-tailed visual recognition

Awesome-LongTailed-Learning

Awesome-of-Long-Tailed-Recognition

Long-Tailed-Classification-Leaderboard

BagofTricks-LT

Connection

If you have any questions, please send the email to Mengke Li at: [email protected].

Citation

@inproceedings{Li2022Long,
  author    = {Mengke Li, Yiu{-}ming Cheung, Yang Lu},
  title     = {Long-tailed Visual Recognition via Gaussian Clouded Logit Adjustment},
  pages = {6929-6938},
  booktitle = {CVPR},
  year      = {2022},
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.