Skip to content

[RFC] Loss functions in quickvision #43

@oke-aditya

Description

@oke-aditya

🚀 Feature

Frequently re-used losses that can be added.

Motivation

Writing Losses is quite repetitive. PyTorch supports losses which are written with deep interoperability with C++ API. But most research losses aren't.

These losses are building blocks for other complicates losses as well.

Pitch

A non-exhaustive and probable list of losses that are not PyTorch but used often.

  • gIoU loss -> Used in Detr (will make porting Detr easier, present in fvcore
  • focal loss -> Used in RetinaNet (It will come in torchvision as well but we we can have here too for re-use, present in fvcore
  • Jsd loss -> Used alternative to CrossEntropy in Classification here
  • Varients of Cross Entropy -> Unsure if they are used often found them here
  • Dice Loss -> Used in U-Net and other segmentation models.
  • Sigmoid Focal Loss -> Modification of Focal loss for segmentation.
  • Huber loss -> Used in efficnet Det and similar loss. Implemented here

Alternatives

Wait for them to reach into fvcore or PyTorch. Till then we keep duplicating these code for models.

Additional context

Note, if we are re-using implementation from any repo. Please cite them on top of code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions