class_docstr: Asynchronous Successive Halving as described in:
  
      @article{li2018massively,
      title={Massively parallel hyperparameter tuning},
      author={Li, Liam and Jamieson, Kevin and Rostamizadeh, Afshin and Gonina, Ekaterina and Hardt, Moritz and Recht, Benjamin and Talwalkar, Ameet},
      journal={arXiv preprint arXiv:1810.05934},
      year={2018}
      }
  
  Asynchronous successive halving operates based on the multi-armed bandit
  algorithm Successive Halving (SHA) and performs principled early stopping for
  random search.
  
  Args:
      r (int): minimum resource that each configuration will be trained for.
      R (int): maximum resource.
      eta (int): elimination rate.
      s (int): minimum early-stopping rate.
      max_finished_configs (int): stop once max_finished_configs models have
          been trained to completion.
class_docstr_tok: ["Asynchronous","Successive","Halving","as","described","in",":","@","article","{","li2018massively",",","title=","{","Massively","parallel","hyperparameter","tuning","}",",","author=","{","Li",",","Liam","and","Jamieson",",","Kevin","and","Rostamizadeh",",","Afshin","and","Gonina",",","Ekaterina","and","Hardt",",","Moritz","and","Recht",",","Benjamin","and","Talwalkar",",","Ameet","}",",","journal=","{","arXiv","preprint","arXiv:1810.05934","}",",","year=","{","2018","}","}","Asynchronous","successive","halving","operates","based","on","the","multi-armed","bandit","algorithm","Successive","Halving","(","SHA",")","and","performs","principled","early","stopping","for","random","search",".","Args",":","r","(","int",")",":","minimum","resource","that","each","configuration","will","be","trained","for",".","R","(","int",")",":","maximum","resource",".","eta","(","int",")",":","elimination","rate",".","s","(","int",")",":","minimum","early-stopping","rate",".","max_finished_configs","(","int",")",":","stop","once","max_finished_configs","models","have","been","trained","to","completion","."]
code: def get_suggestion(self, parameters, results, lower_is_better):
      if (
          self.max_finished_configs
          and len(results) > 0
          and len(
              self._get_completed_results(results, self.number_of_rungs)
          )
          >= self.max_finished_configs
      ):
          return AlgorithmState.DONE
  
      config, k = self.get_job(parameters, results, lower_is_better)
  
      # set new parameters
      config["resource"] = self.r * self.eta ** (self.s + k)
      config["rung"] = k
      config["load_from"] = config.get("save_to", "")
      config["save_to"] = str(self.config_counter)
  
      self.config_counter += 1
      return config
  
file_path: sherpa/sherpa/algorithms/successive_halving.py
imports: from sherpa.algorithms import Algorithm, RandomSearch
  import numpy
  import pandas
  from sherpa.core import TrialStatus, AlgorithmState
label_desc: Use image node_id 3 for calling the SuccessiveHalving obj's underlying member method code with example usage: obj.get_suggestion(parameters, results, lower_is_better) and returns: config, AlgorithmState