code: def __init__(self, save_model_path, patience=10):
      self.patience = patience
      self.counter = 0
      self.best_score = None
      self.early_stop = False
      self.save_model_path = save_model_path
  
imports: import os
  import pickle
  from collections import OrderedDict
  import numpy
  import torch
  import torch.nn
  import yaml
  from scipy import sparse
  from sklearn import preprocessing
  from graph4nlp.pytorch.data.data import GraphData
label_desc: Use image node_id 1 to create a new EarlyStopping object  with example: obj = EarlyStopping(save_model_path, patience)