class_docstr: Tower Generator base class for Phoenix.
class_docstr_tok: ["Tower","Generator","base","class","for","Phoenix","."]
docstr: Waits on a directory till a checkpoint appears in it.
  
  Args:
    model_dir: string - the directory to wait on.
docstr_tok: ["Waits","on","a","directory","till","a","checkpoint","appears","in","it",".","Args",":","model_dir",":","string","-","the","directory","to","wait","on","."]
code: def _wait_for_chief(self, model_dir):
      """Waits on a directory till a checkpoint appears in it.
  
      Args:
        model_dir: string - the directory to wait on.
      """
      my_id = architecture_utils.DirectoryHandler.get_trial_id(
          model_dir, self._phoenix_spec
      )
      while not tf.train.latest_checkpoint(model_dir):
          logging.info("Waiting for chief to create the graph.")
          time.sleep(60)
          if not self._phoenix_spec.HasField("replay"):
              self._metadata.unblock_stopped_infeasible_trial(my_id)
  
file_path: model_search/model_search/generators/base_tower_generator.py
imports: import abc
  import os
  import time
  from typing import List
  from absl import logging
  from model_search.architecture import architecture_utils
  from model_search.architecture import tower
  import tensorflow.compat.v2
label_desc: Use image node_id 2 for calling the BaseTowerGenerator obj's underlying member method code with example usage: obj._wait_for_chief(model_dir) without return types