class_docstr: An iterator that yields Event protos as serialized bytestrings.
class_docstr_tok: ["An","iterator","that","yields","Event","protos","as","serialized","bytestrings","."]
docstr: Loads all new events from disk as raw serialized proto bytestrings.
  
  Calling Load multiple times in a row will not 'drop' events as long as the
  return value is not iterated over.
  
  Yields:
    All event proto bytestrings in the file that have not been yielded yet.
docstr_tok: ["Loads","all","new","events","from","disk","as","raw","serialized","proto","bytestrings",".","Calling","Load","multiple","times","in","a","row","will","not","'drop","'","events","as","long","as","the","return","value","is","not","iterated","over",".","Yields",":","All","event","proto","bytestrings","in","the","file","that","have","not","been","yielded","yet","."]
code: def Load(self):
      """Loads all new events from disk as raw serialized proto bytestrings.
  
      Calling Load multiple times in a row will not 'drop' events as long as the
      return value is not iterated over.
  
      Yields:
        All event proto bytestrings in the file that have not been yielded yet.
      """
      logger.debug("Loading events from %s", self._file_path)
      if self._detect_file_replacement:
          has_increased = self.CheckForIncreasedFileSize()
          # Only act on the file size information if we got a concrete result.
          if has_increased is not None:
              if has_increased:
                  logger.debug(
                      "Reopening %s since file size has changed",
                      self._file_path,
                  )
                  self._iterator.close()
                  self._iterator.reopen()
              else:
                  logger.debug(
                      "Skipping attempt to poll %s since file size has not "
                      "changed (still %d)",
                      self._file_path,
                      self._file_size,
                  )
                  return
      while True:
          try:
              yield next(self._iterator)
          except StopIteration:
              logger.debug("End of file in %s", self._file_path)
              break
          except tf.errors.DataLossError as e:
              # We swallow partial read exceptions; if the record was truncated
              # and a later update completes it, retrying can then resume from
              # the same point in the file since the iterator holds the offset.
              logger.debug(
                  "Truncated record in %s (%s)", self._file_path, e
              )
              break
      logger.debug("No more events in %s", self._file_path)
  
imports: import contextlib
  from tensorboard import data_compat
  from tensorboard import dataclass_compat
  from tensorboard.compat import tf
  from tensorboard.compat.proto import event_pb2
  from tensorboard.util import platform_util
  from tensorboard.util import tb_logging
label_desc: Use image node_id 2 for calling the RawEventFileLoader obj's underlying member method code with example usage: obj.Load() without return types