Skip to content

Pytorch implementation of the paper "Class-Balanced Loss Based on Effective Number of Samples"

License

Notifications You must be signed in to change notification settings

Javadzb/Class-balanced-loss-pytorch

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Class-balanced-loss-pytorch

Pytorch implementation of the paper Class-Balanced Loss Based on Effective Number of Samples presented at CVPR'19.

Yin Cui, Menglin Jia, Tsung-Yi Lin(Google Brain), Yang Song(Google), Serge Belongie

Dependencies

  • Python (>=3.6)
  • Pytorch (>=1.2.0)

Review article of the paper

Medium Article

How it works

It works on the principle of calculating effective number of samples for all classes which is defined as:

alt-text

Thus, the loss function is defined as:

alt-text

Visualisation for effective number of samples

alt-text

References

official tensorflow implementation

About

Pytorch implementation of the paper "Class-Balanced Loss Based on Effective Number of Samples"

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%