parameters: (self, episode_proto)
return_statement: return log_path
docstring: Save episode_proto to self._log_path.
  
      self._log_path is the directory name. A time stamp is the file name of the
      log file. For example, when self._log_path is "/tmp/logs/", the actual
      log file would be "/tmp/logs/yyyy-mm-dd-hh:mm:ss".
  
      Args:
        episode_proto: The proto that holds the states/action for the current
          episode that needs to be save to disk.
      Returns:
        The full log path, including the directory name and the file name.
docstring_summary: Save episode_proto to self._log_path.
docstring_tokens: Save episode_proto to self . _log_path .
function: def save_episode(self, episode_proto):
      """Save episode_proto to self._log_path.
  
      self._log_path is the directory name. A time stamp is the file name of the
      log file. For example, when self._log_path is "/tmp/logs/", the actual
      log file would be "/tmp/logs/yyyy-mm-dd-hh:mm:ss".
  
      Args:
        episode_proto: The proto that holds the states/action for the current
          episode that needs to be save to disk.
      Returns:
        The full log path, including the directory name and the file name.
      """
      if not self._log_path or not episode_proto.state_action:
        return self._log_path
      if not os.path.exists(self._log_path):
        os.mkdir(self._log_path)
      ts = time.time()
      time_stamp = datetime.datetime.fromtimestamp(ts).strftime("%Y-%m-%d-%H%M%S")
      log_path = os.path.join(self._log_path, "minitaur_log_{}".format(time_stamp))
      
      with open(log_path, 'wb') as f:
        f.write(episode_proto.SerializeToString())
      return log_path
function_tokens: def save_episode ( self , episode_proto ) : if not self . _log_path or not episode_proto . state_action : return self . _log_path if not os . path . exists ( self . _log_path ) : os . mkdir ( self . _log_path ) ts = time . time ( ) time_stamp = datetime . datetime . fromtimestamp ( ts ) . strftime ( "%Y-%m-%d-%H%M%S" ) log_path = os . path . join ( self . _log_path , "minitaur_log_{}" . format ( time_stamp ) ) with open ( log_path , 'wb' ) as f : f . write ( episode_proto . SerializeToString ( ) ) return log_path