Learn R Programming

Laurae (version 0.0.0.9001)

loss_Poisson_grad: Laurae's Poisson Error (gradient function)

Description

This function computes the Laurae's Poisson loss gradient per value provided preds and labels count.

Usage

loss_Poisson_grad(y_pred, y_true)

Arguments

y_pred
The predictions.
y_true
The labels.

Value

The gradient of the Laurae's Poisson Error per value.

Details

This loss function is strictly positive, therefore defined in \]0, +Inf\[. It penalizes lower values more heavily, and as such is a good fit for typical problems requiring fine tuning when undercommitting on the predictions. The negative values are cancelled out to make the loss function positive, with loss = 0 when y_true = y_pred. This loss function is experimental. Loss Formula : \((y_pred - y_true * log(y_pred))\) Gradient Formula : \(1 - y_true/y_pred\) Hessian Formula : \(y_true/(y_pred * y_pred)\)