          for key in filetypes:
              if platform.system() == "Linux":
                  filetypes[key] = [item
                                    if item[0] == "All files"
                                    else (item[0], "{} {}".format(item[1], item[1].upper()))
                                    for item in filetypes[key]]
              if len(filetypes[key]) > 2:
                  multi = ["{} Files".format(key.title())]
                  multi.append(" ".join([ftype[1]
                                         for ftype in filetypes[key] if ftype[0] != "All files"]))
 
</s> remove                 multi = ["{} Files".format(key.title())]
 </s> add                 multi = [f"{key.title()} Files"] </s> remove         loss_keys = [key
                     for key in self.display_item.get_loss_keys(Session.session_ids[-1])
                     if key != "total"]
 </s> add         loss_keys = self.display_item.get_loss_keys(Session.session_ids[-1])
        if not loss_keys:
            # Reload if we attempt to get loss keys before data is written
            logger.debug("Waiting for Session Data to become available to graph")
            self.after(1000, self.display_item_process)
            return

        loss_keys = [key for key in loss_keys if key != "total"] </s> remove         texts = ["{} ({})".format(titles[0], side),
                 "{0} > {0}".format(titles[0]),
                 "{} > {}".format(titles[0], titles[1])]
 </s> add         texts = [f"{titles[0]} ({side})",
                 f"{titles[0]} > {titles[0]}",
                 f"{titles[0]} > {titles[1]}"] </s> remove             method = getattr(self, "_calc_{}".format(selection))
 </s> add             method = getattr(self, f"_calc_{selection}") </s> remove         samples = list()
 </s> add         samples = []
                                  else (item[0], f"{item[1]} {item[1].upper()}")
          for key in filetypes:
              if platform.system() == "Linux":
                  filetypes[key] = [item
                                    if item[0] == "All files"
                                  else (item[0], f"{item[1]} {item[1].upper()}")
                                    for item in filetypes[key]]
              if len(filetypes[key]) > 2:
                  multi = ["{} Files".format(key.title())]
                  multi.append(" ".join([ftype[1]
                                         for ftype in filetypes[key] if ftype[0] != "All files"]))
keep keep keep keep replace keep keep keep keep keep
 Update code to support Tensorflow versions up to 2.8 (#1213)

* Update maximum tf version in setup + requirements

* - bump max version of tf version in launcher
- standardise tf version check

* update keras get_custom_objects  for tf>2.6

* bugfix: force black text in GUI file dialogs (linux)

* dssim loss - Move to stock tf.ssim function

* Update optimizer imports for compatibility

* fix logging for tf2.8

* Fix GUI graphing for TF2.8

* update tests

* bump requirements.txt versions

* Remove limit on nvidia-ml-py

* Graphing bugfixes
  - Prevent live graph from displaying if data not yet available

* bugfix: Live graph. Collect loss labels correctly

* fix: live graph - swallow inconsistent loss errors

* Bugfix: Prevent live graph from clearing during training

* Fix graphing for AMD 
lib/gui/utils.py