parameters: (self)
docstring: Clear the internal statistics to initial state.
docstring_summary: Clear the internal statistics to initial state.
docstring_tokens: Clear the internal statistics to initial state .
function: def reset(self):
          """Clear the internal statistics to initial state."""
          if getattr(self, 'num', None) is None:
              self.num_inst = 0
              self.sum_metric = 0.0
          else:
              self.num_inst = [0] * self.num
              self.sum_metric = [0.0] * self.num
          self.records = dict()
          self.counts = dict()
function_tokens: def reset ( self ) : if getattr ( self , 'num' , None ) is None : self . num_inst = 0 self . sum_metric = 0.0 else : self . num_inst = [ 0 ] * self . num self . sum_metric = [ 0.0 ] * self . num self . records = dict ( ) self . counts = dict ( )