code: def __init__(self, patience=10):
      dt = datetime.datetime.now()
      self.filename = "early_stop_{}_{:02d}-{:02d}-{:02d}.pth".format(
          dt.date(), dt.hour, dt.minute, dt.second
      )
      self.patience = patience
      self.counter = 0
      self.best_acc = None
      self.best_loss = None
      self.early_stop = False
  
imports: import datetime
  import errno
  import os
  import pickle
  import random
  from pprint import pprint
  import dgl
  import numpy
  import torch
  from dgl.data.utils import _get_dgl_url, download, get_download_dir
  from scipy import io, sparse
label_desc: Use image node_id 1 to create a new EarlyStopping object from inherited base classes: object with example: obj = EarlyStopping(patience)