We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Describe the bug 在纵向联邦泊松分布损失的计算中,注释写的损失函数和实际代码计算的损失函数不同,注释的损失函数比代码和理论上的损失函数多计算了一次指数。
位置:hetero_poisson_gradient_and_loss.py第80行 详情: Compute hetero poisson loss: loss = sum(exp(mu_g)*exp(mu_h) - y(wx_g + wx_h) + log(exposure)) loss函数中第一部分exp(mu_g)*exp(mu_h) mu_g=exp(wx_g),第一部分就变成了exp(exp(wx_g))exp(exp(wx_h)) 实际代码中 loss_mu = self.forwards.join(host_mu, lambda g, h: g * h).reduce(reduce_add),没有对mu_h和mu_g再计算指数。 因此代码注释可能是 loss = sum(mu_gmu_h - y(wx_g + wx_h) + log(exposure))或 loss = sum(exp(wx_g)*exp(wx_h) - y(wx_g + wx_h) + log(exposure))
The text was updated successfully, but these errors were encountered:
多谢指正,我们计划在近期修改这部分注释代码,可以关注相关pr #5282
Sorry, something went wrong.
No branches or pull requests
Describe the bug
在纵向联邦泊松分布损失的计算中,注释写的损失函数和实际代码计算的损失函数不同,注释的损失函数比代码和理论上的损失函数多计算了一次指数。
位置:hetero_poisson_gradient_and_loss.py第80行
详情: Compute hetero poisson loss:
loss = sum(exp(mu_g)*exp(mu_h) - y(wx_g + wx_h) + log(exposure))
loss函数中第一部分exp(mu_g)*exp(mu_h)
mu_g=exp(wx_g),第一部分就变成了exp(exp(wx_g))exp(exp(wx_h))
实际代码中 loss_mu = self.forwards.join(host_mu, lambda g, h: g * h).reduce(reduce_add),没有对mu_h和mu_g再计算指数。
因此代码注释可能是 loss = sum(mu_gmu_h - y(wx_g + wx_h) + log(exposure))或 loss = sum(exp(wx_g)*exp(wx_h) - y(wx_g + wx_h) + log(exposure))
The text was updated successfully, but these errors were encountered: