          if self._session is None:
              logger.trace("No session loaded. Returning")
              return
          self._summary = None
          self._stats.session = None
          self._stats.tree_clear()
          self._reset_session_info()
          self._session = None
  
      def _load_session(self, full_path=None):
 
</s> remove         if self._session is None:
 </s> add         if not Session.is_loaded: </s> remove         self._reset_session_info()
        self._session = None
 </s> add         if not Session.is_training:
            self._reset_session_info()
            Session.clear() </s> remove         self._session = None
 </s> add  </s> remove             self._stats.session = self._session
 </s> add  </s> remove             self.display_item = session
            if self.trace_var is None:
                self.trace_var = smooth_amount_var.trace("w", self.smooth_amount_callback)
 </s> add             self.display_item = Session
            self._add_trace_variables()
          if self._session is None:
              logger.trace("No session loaded. Returning")
              return
          self._summary = None

          self._stats.tree_clear()
          self._reset_session_info()
          self._session = None
  
      def _load_session(self, full_path=None):
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