Lat fix for Ray HP search (#6691)

This commit is contained in:
Sylvain Gugger 2020-08-24 12:15:00 -04:00 committed by GitHub
parent 3a7fdd3f52
commit 8f98faf934
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 0 deletions

View File

@ -843,6 +843,8 @@ class Trainer:
if getattr(self, "objective", None) is None:
metrics = self.evaluate()
self.objective = self.compute_objective(metrics)
if self.hp_search_backend == HPSearchBackend.RAY:
tune.report(objective=self.objective)
return self.objective
if self.hp_search_backend == HPSearchBackend.OPTUNA: