      """
      def __init__(self, parent):
          logger.debug("Initializing: %s (parent: %s)", self.__class__.__name__, parent)
          self._parent = parent
          self._add_buttons()
          logger.debug("Initialized: %s", self.__class__.__name__)
  
      def _add_buttons(self):
          """ Add the option buttons """
          for btntype in ("clear", "save", "load"):
 
</s> remove         """ Add the option buttons """
 </s> add         """ Add the option buttons.

        Returns
        -------
        dict
            The button names to button objects
        """
        buttons = dict() </s> remove     def _set_help(cls, btntype):
        """ Set the help text for option buttons """
 </s> add     def _set_help(cls, button_type):
        """ Set the help text for option buttons.

        Parameters
        ----------
        button_type: {"reload", "clear", "save", "load"}
            The type of button to set the help text for
        """ </s> remove     def add_label(self):
        """ Add tree-view Title """
 </s> add     def _add_label(self):
        """ Add the title above the tree-view. """ </s> remove     def __init__(self, session):
        logger.debug("Initializing %s: (session: %s)", self.__class__.__name__, session)
        self.session = session
        logger.debug("Initialized %s", self.__class__.__name__)
 </s> add         Parameters
        ----------
        session_id: int
            The session id to compile the stats for
        timestamps:
            The time stamp summary data for the given session id </s> remove         self.session = None  # set when loading or clearing from parent
        self.thread = None  # Thread for loading data popup
        self.selected_id = selected_id
        self.popup_positions = list()

        self.canvas = tk.Canvas(self, bd=0, highlightthickness=0)
        self.canvas.pack(side=tk.LEFT, fill=tk.BOTH, expand=True)

        self.tree_frame = ttk.Frame(self.canvas)
        self.tree_canvas = self.canvas.create_window((0, 0), window=self.tree_frame, anchor=tk.NW)
        self.sub_frame = ttk.Frame(self.tree_frame)
        self.sub_frame.pack(side=tk.LEFT, fill=tk.X, anchor=tk.N, expand=True)

        self.add_label()
        self.tree = ttk.Treeview(self.sub_frame, height=1, selectmode=tk.BROWSE)
        self.scrollbar = ttk.Scrollbar(self.tree_frame, orient="vertical", command=self.tree.yview)
        self.scrollbar.pack(side=tk.RIGHT, fill=tk.Y)

        self.columns = self.tree_configure(helptext)
        self.canvas.bind("<Configure>", self.resize_frame)
 </s> add 
        self._buttons = self._add_buttons()
        self._add_training_callback()
      """
      def __init__(self, parent):
          logger.debug("Initializing: %s (parent: %s)", self.__class__.__name__, parent)
          self._parent = parent
        self._buttons = self._add_buttons()
        self._add_training_callback()
          logger.debug("Initialized: %s", self.__class__.__name__)
  
      def _add_buttons(self):
          """ Add the option buttons """
          for btntype in ("clear", "save", "load"):
keep keep keep keep replace keep keep keep keep keep
 GUI - Stats optimization (#1067)

* Faster stat loading + caching

* Compress data in cache

* Optimize some calculations

* Vectorize smoothing

* stats.Calculations optimized

* Load latest training data from live iterator

* Add options to training graph 
lib/gui/display_analysis.py