From dc0b1675520e435cfe3ef939ccf45fff780b7bec Mon Sep 17 00:00:00 2001 From: angelinalg <122562471+angelinalg@users.noreply.github.com> Date: Fri, 30 Jun 2023 15:39:42 -0700 Subject: [PATCH 1/2] fix code indentation Signed-off-by: angelinalg <122562471+angelinalg@users.noreply.github.com> --- doc/source/index.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/source/index.md b/doc/source/index.md index 2f0e680473e51..33d1db1b4402e 100644 --- a/doc/source/index.md +++ b/doc/source/index.md @@ -101,7 +101,8 @@ class HuggingFacePredictor: # Logic for inference on 1 batch of data. def __call__(self, batch: Dict[str, np.ndarray]) -> Dict[str, list]: # Get the predictions from the input batch. - predictions = self.model(list(batch["data"]), max_length=20, num_return_sequences=1) + predictions = self.model(list(batch["data"]), max_length=20, + num_return_sequences=1) # `predictions` is a list of length-one lists. For example: # [[{'generated_text': 'output_1'}], ..., [{'generated_text': 'output_2'}]] # Modify the output to get it into the following format instead: @@ -181,8 +182,7 @@ trainer = LightGBMTrainer( tuner = tune.Tuner( trainer=trainer, param_space=hyper_param_space, - tune_config=tune.TuneConfig(num_sa - les=1000), + tune_config=tune.TuneConfig(num_samples=1000), ) # Step 3: run distributed HPO with 1000 trials; each trial runs on 64 CPUs From 806275929b69a963d1406007faa9702029a71fb5 Mon Sep 17 00:00:00 2001 From: Philipp Moritz Date: Fri, 30 Jun 2023 23:38:25 -0700 Subject: [PATCH 2/2] Update index.md Signed-off-by: Philipp Moritz --- doc/source/index.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/source/index.md b/doc/source/index.md index 33d1db1b4402e..7a71b298da60a 100644 --- a/doc/source/index.md +++ b/doc/source/index.md @@ -101,8 +101,8 @@ class HuggingFacePredictor: # Logic for inference on 1 batch of data. def __call__(self, batch: Dict[str, np.ndarray]) -> Dict[str, list]: # Get the predictions from the input batch. - predictions = self.model(list(batch["data"]), max_length=20, - num_return_sequences=1) + predictions = self.model( + list(batch["data"]), max_length=20, num_return_sequences=1) # `predictions` is a list of length-one lists. For example: # [[{'generated_text': 'output_1'}], ..., [{'generated_text': 'output_2'}]] # Modify the output to get it into the following format instead: