code: def visualize_mask(mask, num_cls):
      palette = get_palette(num_cls)
      mask[mask == -1] = 0
  
      return palette[mask].astype(np.uint8)
  
file_path: PaddleSeg/EISeg/eiseg/util/vis.py
imports: from functools import lru_cache
  import cv2
  import numpy
label_desc: Use image node_id 3 for calling a global function with example usage: visualize_mask(mask, num_cls) and returns: palette