class_docstr: Tune driver
class_docstr_tok: ["Tune","driver"]
docstr: Run trials
  :return: trials result
docstr_tok: ["Run","trials",":","return",":","trials","result"]
code: def run(self):
      """
      Run trials
      :return: trials result
      """
      analysis = tune.run(
          self.train_func,
          local_dir=self.logs_dir,
          metric=self.metric_name,
          mode=self.mode,
          name=self.name,
          stop=self.stopper,
          config=self.search_space,
          search_alg=self._search_alg,
          num_samples=self.num_samples,
          trial_dirname_creator=trial_dirname_creator,
          scheduler=self._scheduler,
          resources_per_trial=self.resources_per_trial,
          verbose=1,
          reuse_actors=True,
      )
      self.trials = analysis.trials
  
      # Visualization code for ray (leaderboard)
      logger_name = self.name if self.name else DEFAULT_LOGGER_NAME
      (
          tf_config,
          tf_metric,
      ) = TensorboardLogger._ray_tune_searcher_log_adapt(analysis)
  
      self.logger = TensorboardLogger(
          logs_dir=os.path.join(
              self.logs_dir, logger_name + "_leaderboard"
          ),
          name=logger_name,
      )
      self.logger.run(tf_config, tf_metric)
      self.logger.close()
  
      return analysis
  
imports: import ray
  from ray import tune
  import os
  from zoo.orca.automl.search.base import SearchEngine, TrialOutput, GoodError
  from zoo.orca.automl.search.parameters import DEFAULT_LOGGER_NAME, DEFAULT_METRIC_NAME
  from zoo.orca.automl.search.ray_tune.utils import convert_bayes_configs
  from zoo.orca.automl.search.utils import get_ckpt_hdfs, put_ckpt_hdfs
  from zoo.orca.automl.search import TensorboardLogger
  from ray.tune import Stopper
  from zoo.orca.automl.model.abstract import ModelBuilder
label_desc: Use image node_id 6 for calling the RayTuneSearchEngine obj's underlying member method code with example usage: obj.run() and returns: analysis