Skip to content

Commit

Permalink
Fix gamma neg log likelihood.
Browse files Browse the repository at this point in the history
  • Loading branch information
trivialfis committed Sep 29, 2021
1 parent b2d8431 commit ee64178
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/metric/elementwise_metric.cu
Original file line number Diff line number Diff line change
Expand Up @@ -309,8 +309,7 @@ struct EvalGammaNLogLik {
float constexpr kPsi = 1.0;
bst_float theta = -1. / py;
bst_float a = kPsi;
// b = -std::log(-theta);
float b = 1.0f;
float b = -std::log(-theta);
// c = 1. / kPsi * std::log(y/kPsi) - std::log(y) - common::LogGamma(1. / kPsi);
// = 1.0f * std::log(y) - std::log(y) - 0 = 0
float c = 0;
Expand Down

0 comments on commit ee64178

Please sign in to comment.