class_docstr: Logs a series of values.
  
  The values are displayed and/or output to the file
  ``<name>-series.txt``.
  
  Example:
  
  .. code-block:: python
  
      mons = MonitorSeries('mon', interval=2)
      for i in range(10):
          mons.add(i, i * 2)
  
  Args:
      name (str): Name of the monitor. Used in the log.
      monitor (~nnabla.monitor.Monitor): Monitor class instance.
      interval (int): Interval of flush the outputs. The values added by
          ``.add()`` are averaged during interval.
      verbose (bool): Output to screen.
class_docstr_tok: ["Logs","a","series","of","values",".","The","values","are","displayed","and\/or","output","to","the","file","``","<","name",">","-series.txt","``",".","Example",":","..","code-block",":",":","python","mons","=","MonitorSeries","(","'mon","'",",","interval=2",")","for","i","in","range","(","10",")",":","mons.add","(","i",",","i","*","2",")","Args",":","name","(","str",")",":","Name","of","the","monitor",".","Used","in","the","log",".","monitor","(","~nnabla.monitor.Monitor",")",":","Monitor","class","instance",".","interval","(","int",")",":","Interval","of","flush","the","outputs",".","The","values","added","by","``",".add","(",")","``","are","averaged","during","interval",".","verbose","(","bool",")",":","Output","to","screen","."]
code: def __init__(self, name, monitor=None, interval=1, verbose=True):
      self.name = name
      self.interval = interval
      self.verbose = verbose
      self.sp = None
      if monitor is not None:
          self.sp = (
              os.path.join(monitor.save_path, name.replace(" ", "-"))
              + ".series.txt"
          )
          # refresh output file
          with open(self.sp, "w") as f:
              pass
      self.flush_at = -1
      self.buf = []
  
imports: from __future__ import print_function
  import numpy
  import os
  import time
  from nnabla.logger import logger
label_desc: Use image node_id 1 to create a new MonitorSeries object from inherited base classes: object with example: obj = MonitorSeries(name, monitor, interval, verbose)