          limit = max(0, limit)
          logger.debug("Setting iteration limit to: %s", limit)
          self._limit = limit
  
      def _get_raw(self):
          """ Obtain the raw loss values and add them to a new :attr:`stats` dictionary. """
          logger.debug("Getting Raw Data")
          self.stats.clear()
          iterations = set()
  
 
</s> remove         mean = np.mean(data)
        limit = np.std(data)
 </s> add         mean = np.mean(np.nan_to_num(data))
        limit = np.std(np.nan_to_num(data)) </s> remove     def start_iteration(self):
 </s> add     def start_iteration(self) -> int: </s> remove     def get_loss(self, session_id):
 </s> add     def get_loss(self, session_id: Optional[int]) -> dict: </s> remove     def set_iterations_limit(self, limit):
 </s> add     def set_iterations_limit(self, limit: int) -> None: </s> remove     def stats(self):
 </s> add     def stats(self) -> dict:
    def _get_raw(self) -> None:
          limit = max(0, limit)
          logger.debug("Setting iteration limit to: %s", limit)
          self._limit = limit
  
    def _get_raw(self) -> None:
          """ Obtain the raw loss values and add them to a new :attr:`stats` dictionary. """
          logger.debug("Getting Raw Data")
          self.stats.clear()
          iterations = set()
  
keep keep keep keep replace keep keep keep keep keep
 Bugfixes:
  - Stats graph - Handle NaNs in data
  - logger - de-elevate matplotlib font messages 
lib/gui/analysis/stats.py