code: def configure(logdir, flush_secs=2):
      
      global _default_logger
      if _default_logger is not None:
          raise ValueError('default logger already configured')
      _default_logger = Logger(logdir, flush_secs=flush_secs)
docs: Configure logging: a file will be written to logdir, and flushed
      every flush_secs.