pytorch
11e51749 - Added support for Huber Loss (#37599)

Commit
4 years ago
Added support for Huber Loss (#37599) Summary: Current losses in PyTorch only include a (partial) implementation of Huber loss through `smooth l1` based on Fast RCNN - which essentially uses a delta value of 1. Changing/Renaming the [`_smooth_l1_loss()`](https://github.com/pytorch/pytorch/blob/3e1859959a3f720bb5f5e47c3ca15fb3cbfae4da/torch/nn/functional.py#L2487) and refactoring to include delta, enables to use the actual function. Supplementary to this, I have also made a functional and criterion versions for anyone that wants to set the delta explicitly - based on the functional `smooth_l1_loss()` and the criterion `Smooth_L1_Loss()` Pull Request resolved: https://github.com/pytorch/pytorch/pull/37599 Differential Revision: D21559311 Pulled By: vincentqb fbshipit-source-id: 34b2a5a237462e119920d6f55ba5ab9b8e086a8c
Parents
Loading