original_docstring:  Compile the Totals stats.
          Totals are fully calculated each time as they will change on the basis of the training
          session.
  
          Returns
          -------
          dict:
              The Session name, start time, end time, elapsed time, rate, batch size and number of
              iterations for all session ids within the loaded data.
          
docstring: Compile the Totals stats.
  Totals are fully calculated each time as they will change on the basis of the training
  session.
  
  Returns
  
  The Session name, start time, end time, elapsed time, rate, batch size and number of
  iterations for all session ids within the loaded data.
docstring_tokens: Compile the Totals stats . Totals are fully calculated each time as they will change on the basis of the training session . Returns The Session name start time end time elapsed time rate batch size and number of iterations for all session ids within the loaded data .
code: def _total_stats(self):
          """ Compile the Totals stats.
          Totals are fully calculated each time as they will change on the basis of the training
          session.
  
          Returns
          -------
          dict:
              The Session name, start time, end time, elapsed time, rate, batch size and number of
              iterations for all session ids within the loaded data.
          """
          logger.debug("Compiling Totals")
          elapsed = 0
          examples = 0
          iterations = 0
          batchset = set()
          total_summaries = len(self._per_session_stats)
          for idx, summary in enumerate(self._per_session_stats):
              if idx == 0:
                  starttime = summary["start"]
              if idx == total_summaries - 1:
                  endtime = summary["end"]
              elapsed += summary["elapsed"]
              examples += ((summary["batch"] * 2) * summary["iterations"])
              batchset.add(summary["batch"])
              iterations += summary["iterations"]
          batch = ",".join(str(bs) for bs in batchset)
          totals = {"session": "Total",
                    "start": starttime,
                    "end": endtime,
                    "elapsed": elapsed,
                    "rate": examples / elapsed if elapsed != 0 else 0,
                    "batch": batch,
                    "iterations": iterations}
          logger.debug(totals)
          return totals
code_tokens: def _total_stats ( self ) : logger . debug ( "Compiling Totals" ) elapsed = 0 examples = 0 iterations = 0 batchset = set ( ) total_summaries = len ( self . _per_session_stats ) for idx , summary in enumerate ( self . _per_session_stats ) : if idx == 0 : starttime = summary [ "start" ] if idx == total_summaries - 1 : endtime = summary [ "end" ] elapsed += summary [ "elapsed" ] examples += ( ( summary [ "batch" ] * 2 ) * summary [ "iterations" ] ) batchset . add ( summary [ "batch" ] ) iterations += summary [ "iterations" ] batch = "," . join ( str ( bs ) for bs in batchset ) totals = { "session" : "Total" , "start" : starttime , "end" : endtime , "elapsed" : elapsed , "rate" : examples / elapsed if elapsed != 0 else 0 , "batch" : batch , "iterations" : iterations } logger . debug ( totals ) return totals
short_docstring: Compile the Totals stats.
short_docstring_tokens: Compile the Totals stats .
comment: """ Compile the Totals stats.
          Totals are fully calculated each time as they will change on the basis of the training
          session.
  
          Returns
          -------
          dict:
              The Session name, start time, end time, elapsed time, rate, batch size and number of
              iterations for all session ids within the loaded data.
          """