Skip to content
This repository has been archived by the owner on Jul 20, 2024. It is now read-only.

styler00dollar/pytorch-loss-functions

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pytorch-loss-functions

This repo is a combination of victorca25/BasicSR, mit-han-lab/data-efficient-gans and huster-wgm/Pytorch-metrics.

It aims to make the usage of different loss function, metrics and dataset augmentation easy and avoids using pip or other external depenencies.

Currently usable without major problems and with example usage in example.py:

  • Differentiable Augmentation
  • Metrics (PSNR, SSIM, AE, MSE)
  • HFEN Loss (High Frequency Error Norm) [1 2]
  • Elastic Loss
  • Relative L1
  • L1 (CosineSim) [1 2]
  • Clip L1 [1]
  • FFT Loss (Frequency loss) [1]
  • OF Loss (Overflow loss) [1]
  • GP Loss (Gradient Profile Loss) [1]
  • CP Loss (Color Profile Loss)
  • Style Loss [1 2] (Warning: No AMP support.)
  • TV Loss (Total Variation Loss)
  • Perceptual Loss (LPIPS)
  • Contextual Loss [1 2 3 4]

May be added in the future in example.py, but already in loss.py:

  • Charbonnier Loss (L1)
  • GAN Loss
  • Gradient Loss
  • Masked L1 Loss
  • Multiscale Pixel Loss
  • OFR Loss (Optical flow reconstruction loss (for video)) [1]
  • L1 regularization
  • Color Loss
  • Average Loss (Averaging Downscale loss)
  • SPL Compute With Trace (Spatial Profile Loss with trace)
  • SP Loss (Spatial Profile Loss without trace)

About

A collection of loss functions with easy usage

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages