code: def ScalerMinMax(X: torch.Tensor) -> torch.Tensor:
      """
      Min-max scale the input affinity matrix X, which will lead to a dynamic range of [0, 1].
  
      Args:
          X (Tensor):
              Matrix containing cosine similarity values among embedding vectors (N x N)
  
      Returns:
          v_norm (Tensor):
              Min-max normalized value of X.
      """
      v_min, v_max = X.min(), X.max()
      v_norm = (X - v_min) / (v_max - v_min)
      return v_norm
  
imports: from typing import Dict, List, Tuple
  import torch
  from torch.linalg import eigh, eigvalsh
label_desc: Use image node_id 2 for calling a global function with example usage: ScalerMinMax(X) and returns: v_norm