parameters: (self,
                 init_op=None,
                 init_feed_dict=None,
                 init_fn=None,
                 ready_op=None,
                 ready_for_local_init_op=None,
                 local_init_op=None,
                 summary_op=None,
                 saver=None,
                 copy_from_scaffold=None)
docstring: Create a scaffold.
  
      Args:
        init_op: Optional op for initializing variables.
        init_feed_dict: Optional session feed dictionary to use when running the
          init_op.
        init_fn: Optional function to use to initialize the model after running
          the init_op.  Will be called as `init_fn(scaffold, session)`.
        ready_op: Optional op to verify that the variables are initialized.  Must
          return an empty 1D string tensor when the variables are initialized, or
          a non-empty 1D string tensor listing the names of the non-initialized
          variables.
        ready_for_local_init_op: Optional op to verify that the global variables
          are initialized and `local_init_op` can be run. Must return an empty
          1D string tensor when the global variables are initialized, or a
          non-empty 1D string tensor listing the names of the non-initialized
          global variables.
        local_init_op: Optional op to initialize local variables.
        summary_op: Optional op to gather all summaries.  Must return a scalar
          string tensor containing a serialized `Summary` proto.
        saver: Optional `tf.train.Saver` object to use to save and restore
          variables.
        copy_from_scaffold: Optional scaffold object to copy fields from. Its
          fields will be overwritten by the provided fields in this function.
docstring_summary: Create a scaffold.
docstring_tokens: Create a scaffold .
function: def __init__(self,
                 init_op=None,
                 init_feed_dict=None,
                 init_fn=None,
                 ready_op=None,
                 ready_for_local_init_op=None,
                 local_init_op=None,
                 summary_op=None,
                 saver=None,
                 copy_from_scaffold=None):
      """Create a scaffold.
  
      Args:
        init_op: Optional op for initializing variables.
        init_feed_dict: Optional session feed dictionary to use when running the
          init_op.
        init_fn: Optional function to use to initialize the model after running
          the init_op.  Will be called as `init_fn(scaffold, session)`.
        ready_op: Optional op to verify that the variables are initialized.  Must
          return an empty 1D string tensor when the variables are initialized, or
          a non-empty 1D string tensor listing the names of the non-initialized
          variables.
        ready_for_local_init_op: Optional op to verify that the global variables
          are initialized and `local_init_op` can be run. Must return an empty
          1D string tensor when the global variables are initialized, or a
          non-empty 1D string tensor listing the names of the non-initialized
          global variables.
        local_init_op: Optional op to initialize local variables.
        summary_op: Optional op to gather all summaries.  Must return a scalar
          string tensor containing a serialized `Summary` proto.
        saver: Optional `tf.train.Saver` object to use to save and restore
          variables.
        copy_from_scaffold: Optional scaffold object to copy fields from. Its
          fields will be overwritten by the provided fields in this function.
      """
      if copy_from_scaffold is not None:
        if not isinstance(copy_from_scaffold, Scaffold):
          raise TypeError('copy_from_scaffold is not a Scaffold instance.')
        # We need _coalesce since Tensor is not converted to bool automatically,
        # so the common idiom of (a or b) does not work.
        coalesce = lambda a, b: a if a is not None else b
        init_op = coalesce(init_op, copy_from_scaffold.init_op)
        init_feed_dict = coalesce(init_feed_dict,
                                  copy_from_scaffold.init_feed_dict)
        # Use the original init_fn provided by the user to init the new Scaffold.
        init_fn = coalesce(init_fn, copy_from_scaffold._user_init_fn)  # pylint: disable=protected-access
        ready_op = coalesce(ready_op, copy_from_scaffold.ready_op)
        ready_for_local_init_op = coalesce(
            ready_for_local_init_op, copy_from_scaffold.ready_for_local_init_op)
        local_init_op = coalesce(local_init_op, copy_from_scaffold.local_init_op)
        summary_op = coalesce(summary_op, copy_from_scaffold.summary_op)
        saver = coalesce(saver, copy_from_scaffold.saver)
  
      # NOTE(touts): modifying the init function to be passed the scaffold is a
      # hack to make it easy to find the saver.  Is there a better way?
      self._user_init_fn = init_fn
      if init_fn:
        self._init_fn = lambda sess: init_fn(self, sess)
      else:
        self._init_fn = None
  
      self._init_op = init_op
      self._init_feed_dict = init_feed_dict
      self._ready_op = ready_op
      self._ready_for_local_init_op = ready_for_local_init_op
      self._local_init_op = local_init_op
      self._summary_op = summary_op
      self._saver = saver
function_tokens: def __init__ ( self , init_op = None , init_feed_dict = None , init_fn = None , ready_op = None , ready_for_local_init_op = None , local_init_op = None , summary_op = None , saver = None , copy_from_scaffold = None ) : if copy_from_scaffold is not None : if not isinstance ( copy_from_scaffold , Scaffold ) : raise TypeError ( 'copy_from_scaffold is not a Scaffold instance.' ) # We need _coalesce since Tensor is not converted to bool automatically, # so the common idiom of (a or b) does not work. coalesce = lambda a , b : a if a is not None else b init_op = coalesce ( init_op , copy_from_scaffold . init_op ) init_feed_dict = coalesce ( init_feed_dict , copy_from_scaffold . init_feed_dict ) # Use the original init_fn provided by the user to init the new Scaffold. init_fn = coalesce ( init_fn , copy_from_scaffold . _user_init_fn ) # pylint: disable=protected-access ready_op = coalesce ( ready_op , copy_from_scaffold . ready_op ) ready_for_local_init_op = coalesce ( ready_for_local_init_op , copy_from_scaffold . ready_for_local_init_op ) local_init_op = coalesce ( local_init_op , copy_from_scaffold . local_init_op ) summary_op = coalesce ( summary_op , copy_from_scaffold . summary_op ) saver = coalesce ( saver , copy_from_scaffold . saver ) # NOTE(touts): modifying the init function to be passed the scaffold is a # hack to make it easy to find the saver.  Is there a better way? self . _user_init_fn = init_fn if init_fn : self . _init_fn = lambda sess : init_fn ( self , sess ) else : self . _init_fn = None self . _init_op = init_op self . _init_feed_dict = init_feed_dict self . _ready_op = ready_op self . _ready_for_local_init_op = ready_for_local_init_op self . _local_init_op = local_init_op self . _summary_op = summary_op self . _saver = saver