Skip to content

Possible Error in DER Loss, Matching Losses from TF Implementation #205

@EdwardBerman

Description

@EdwardBerman

Dear all,
I came across the ML4PS paper regarding this work recently, and found it super useful to a study I am conducting! Great work.

I was wondering if someone could look into the definition of the DER loss. I am comparing with this TensorFlow implementation from the original paper here . Firstly, in line 453 in your models.py, I think there should be a 1/beta term. You have

           + (coeff * torch.abs(error / w_st) * (2.0 * nu + alpha))

but the original paper defines in equation 12 this part to be $\rho_q (y_i − \gamma_i) · \phi$ where $\phi_i = 2 \nu_i + \alpha_i + 1/\beta_i$

Additionally, they define the width of the distribution through sampling an exponential as such

    tfd = tfp.distributions
    theta = (1.0-2.0*quantile)/(quantile*(1.0-quantile))
    mean_ = beta/(alpha-1)

    w_i_dis = tfd.Exponential(rate=1/mean_)

However, it appears you guys define it via

 w_st = torch.sqrt(beta * (1 + nu) / (alpha * nu))

I'm a little new to this area, so it's very possible I'm missing something. I'm also happy to submit a PR and contribute to the development of this package.

All the best,
Eddie

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions