Skip to content

Commit

Permalink
log loss
Browse files Browse the repository at this point in the history
Signed-off-by: weijingchen <talkingwallace@sohu.com>

Signed-off-by: cwj <talkingwallace@sohu.com>
  • Loading branch information
talkingwallace committed Nov 21, 2023
1 parent 9510f6c commit 7978762
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion python/fate/ml/ensemble/algo/secureboost/hetero/guest.py
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,9 @@ def fit(self, ctx: Context, train_data: DataFrame, validate_data: DataFrame = No

# compute loss
iter_loss = self._loss_func.compute_loss(train_data.label, self._loss_func.predict(self._accumulate_scores))
self._loss_history.append(float(iter_loss.iloc[0]))
iter_loss = float(iter_loss.iloc[0])
self._loss_history.append(iter_loss)
tree_ctx.metrics.log_loss('sbt_loss', iter_loss)

# compute train predict using cache scores
train_predict: DataFrame = self._loss_func.predict(self._accumulate_scores)
Expand Down

0 comments on commit 7978762

Please sign in to comment.