Skip to content

Commit

Permalink
Fix xgboost model overwrite (#2663)
Browse files Browse the repository at this point in the history
  • Loading branch information
YuanTingHsieh authored Jun 25, 2024
1 parent 4f604bb commit e63c4f6
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ class since the self object contains a sender that contains a Core Cell which ca
Returns: None
"""
simulate_mode = fl_ctx.get_prop(FLContextKey.SIMULATE_MODE, False)
model_dir = self._app_dir if simulate_mode else self._run_dir
runner_ctx = {
Constant.RUNNER_CTX_WORLD_SIZE: self.world_size,
Constant.RUNNER_CTX_CLIENT_NAME: self._client_name,
Expand All @@ -76,7 +78,7 @@ class since the self object contains a sender that contains a Core Cell which ca
Constant.RUNNER_CTX_TRAINING_MODE: self.training_mode,
Constant.RUNNER_CTX_XGB_PARAMS: self.xgb_params,
Constant.RUNNER_CTX_XGB_OPTIONS: self.xgb_options,
Constant.RUNNER_CTX_MODEL_DIR: self._run_dir,
Constant.RUNNER_CTX_MODEL_DIR: model_dir,
Constant.RUNNER_CTX_TB_DIR: self._app_dir,
}
self.start_runner(runner_ctx, fl_ctx)
Expand Down

0 comments on commit e63c4f6

Please sign in to comment.