class_docstr: A grouping of Timers.
class_docstr_tok: ["A","grouping","of","Timers","."]
code: def stats(self, mean=True, last=False):
      aggregates = {}
      for k, t in self._timers.items():
          if t.count > 0:
              if mean:
                  aggregates["mean_%s_s" % k] = t.mean
              if last:
                  aggregates["last_%s_s" % k] = t.last
      return aggregates
  
imports: import time
  import numbers
  import socket
  import collections
  import numpy
  from contextlib import closing, contextmanager
  import torch
  from bigdl.dllib.utils.log4Error import *
label_desc: Use image node_id 6 for calling the TimerCollection obj's underlying member method code with example usage: obj.stats(mean, last) and returns: aggregates