code: def manual_seed(seed: int = 1) -> None:
      """
      设置seed。
      """
      random.seed(seed)
      np.random.seed(seed)
      torch.manual_seed(seed)
      torch.cuda.manual_seed(seed)
      torch.cuda.manual_seed_all(seed)
      # if torch.cuda.CUDA_ENABLED and use_deterministic_cudnn:
      torch.backends.cudnn.deterministic = True
      torch.backends.cudnn.benchmark = False
  
file_path: DeepKE/src/deepke/relation_extraction/standard/utils/nnUtils.py
imports: import torch
  import random
  import logging
  import numpy
  from typing import List, Tuple, Dict, Union
label_desc: Use image node_id 1 for calling a global function with example usage: manual_seed(seed) without return types