code: def print_every_class_eval(self, out_16_13=False, logger=None):
      MIoU = np.diag(self.confusion_matrix) / (
          np.sum(self.confusion_matrix, axis=1)
          + np.sum(self.confusion_matrix, axis=0)
          - np.diag(self.confusion_matrix)
      )
      MPA = np.diag(self.confusion_matrix) / self.confusion_matrix.sum(
          axis=1
      )
      Precision = np.diag(
          self.confusion_matrix
      ) / self.confusion_matrix.sum(axis=0)
      Class_ratio = np.sum(self.confusion_matrix, axis=1) / np.sum(
          self.confusion_matrix
      )
      Pred_retio = np.sum(self.confusion_matrix, axis=0) / np.sum(
          self.confusion_matrix
      )
      log_fn = print if logger is None else logger.info
      log_fn(
          "===>Everyclass:\t"
          + "MPA\t"
          + "MIoU\t"
          + "PC\t"
          + "Ratio\t"
          + "Pred_Retio"
      )
      # if out_16_13: MIoU = MIoU[synthia_set_16]
      for ind_class in range(len(MIoU)):
          pa = (
              str(round(MPA[ind_class] * 100, 2))
              if not np.isnan(MPA[ind_class])
              else "nan"
          )
          iou = (
              str(round(MIoU[ind_class] * 100, 2))
              if not np.isnan(MIoU[ind_class])
              else "nan"
          )
          pc = (
              str(round(Precision[ind_class] * 100, 2))
              if not np.isnan(Precision[ind_class])
              else "nan"
          )
          cr = (
              str(round(Class_ratio[ind_class] * 100, 2))
              if not np.isnan(Class_ratio[ind_class])
              else "nan"
          )
          pr = (
              str(round(Pred_retio[ind_class] * 100, 2))
              if not np.isnan(Pred_retio[ind_class])
              else "nan"
          )
          log_fn(
              "===>"
              + name_classes[ind_class]
              + ":\t"
              + pa
              + "\t"
              + iou
              + "\t"
              + pc
              + "\t"
              + cr
              + "\t"
              + pr
          )
  
imports: import os
  import time
  import tqdm
  import numpy
  from PIL import Image
  import paddle
  import paddle.nn.functional
  from paddleseg.utils import metrics, TimeAverager, calculate_eta, logger, progbar
  import datasets
  from utils import save_imgs
label_desc: Use image node_id 7 for calling the Eval obj's underlying member method code with example usage: obj.print_every_class_eval(out_16_13, logger) without return types