Merge pull request #1241 from KhaoticMind/master

[py]Preserve the actual objective used on the booster - Fixed #1215
This commit is contained in:
Yuan (Terry) Tang 2016-06-01 09:11:49 -05:00
commit 9ef86072f4

View File

@ -441,6 +441,7 @@ class XGBClassifier(XGBModel, XGBClassifierBase):
evals_result=evals_result, obj=obj, feval=feval,
verbose_eval=verbose)
self.objective = xgb_options["objective"]
if evals_result:
for val in evals_result.items():
evals_result_key = list(val[1].keys())[0]