class_docstr: 注意，如果显示的图像不全，是matplotlib版本问题
  本例程使用matplotlib-3.2.1(windows and ubuntu)绘制正常
  需要额外安装prettytable库
class_docstr_tok: ["\u6ce8\u610f\uff0c\u5982\u679c\u663e\u793a\u7684\u56fe\u50cf\u4e0d\u5168\uff0c\u662fmatplotlib\u7248\u672c\u95ee\u9898","\u672c\u4f8b\u7a0b\u4f7f\u7528matplotlib-3.2.1","(","windows","and","ubuntu",")","\u7ed8\u5236\u6b63\u5e38","\u9700\u8981\u989d\u5916\u5b89\u88c5prettytable\u5e93"]
code: def update(self, preds, labels):
      for p, t in zip(preds, labels):
          self.matrix[p, t] += 1
  
file_path: deep-learning-for-image-processing/pytorch_classification/swin_transformer/create_confusion_matrix.py
imports: import os
  import json
  import argparse
  import sys
  import torch
  from torchvision import transforms
  import numpy
  from tqdm import tqdm
  import matplotlib.pyplot
  from prettytable import PrettyTable
  from utils import read_split_data
  from my_dataset import MyDataSet
  from model import swin_base_patch4_window12_384_in22k
label_desc: Use image node_id 2 for calling the ConfusionMatrix obj's underlying member method code with example usage: obj.update(preds, labels) without return types