mirror of
https://github.com/vale981/ray
synced 2025-03-05 18:11:42 -05:00
[Tune] Remove runner
argument in start_trial. (#20464)
This internal legacy argument was not used by any code.
This commit is contained in:
parent
d1c624901f
commit
03aec4e04a
1 changed files with 4 additions and 8 deletions
|
@ -466,8 +466,7 @@ class RayTrialExecutor(TrialExecutor):
|
|||
trial_item = self._find_item(self._running, trial)
|
||||
assert len(trial_item) < 2, trial_item
|
||||
|
||||
def _start_trial(self, trial, checkpoint=None, runner=None,
|
||||
train=True) -> bool:
|
||||
def _start_trial(self, trial, checkpoint=None, train=True) -> bool:
|
||||
"""Starts trial and restores last result if trial was paused.
|
||||
|
||||
Args:
|
||||
|
@ -475,8 +474,6 @@ class RayTrialExecutor(TrialExecutor):
|
|||
checkpoint (Optional[Checkpoint]): The checkpoint to restore from.
|
||||
If None, and no trial checkpoint exists, the trial is started
|
||||
from the beginning.
|
||||
runner (Trainable): The remote runner to use. This can be the
|
||||
cached actor. If None, a new runner is created.
|
||||
train (bool): Whether or not to start training.
|
||||
|
||||
Returns:
|
||||
|
@ -486,10 +483,9 @@ class RayTrialExecutor(TrialExecutor):
|
|||
"""
|
||||
prior_status = trial.status
|
||||
self.set_status(trial, Trial.PENDING)
|
||||
if runner is None:
|
||||
runner = self._setup_remote_runner(trial)
|
||||
if not runner:
|
||||
return False
|
||||
runner = self._setup_remote_runner(trial)
|
||||
if not runner:
|
||||
return False
|
||||
trial.set_runner(runner)
|
||||
self._notify_trainable_of_new_resources_if_needed(trial)
|
||||
self.restore(trial, checkpoint)
|
||||
|
|
Loading…
Add table
Reference in a new issue