code: def imread_uint(path, n_channels=3):
      #  input: path
      # output: HxWx3(RGB or GGG), or HxWx1 (G)
      if n_channels == 1:
          img = cv2.imread(path, 0)  # cv2.IMREAD_GRAYSCALE
          img = np.expand_dims(img, axis=2)  # HxWx1
      elif n_channels == 3:
          img = cv2.imread(path, cv2.IMREAD_UNCHANGED)  # BGR or G
          if img.ndim == 2:
              img = cv2.cvtColor(img, cv2.COLOR_GRAY2RGB)  # GGG
          else:
              img = cv2.cvtColor(img, cv2.COLOR_BGR2RGB)  # RGB
      return img
  
imports: import os
  import math
  import random
  import numpy
  import torch
  import cv2
  from torchvision.utils import make_grid
  from datetime import datetime
label_desc: Use image node_id 13 for calling a global function with example usage: imread_uint(path, n_channels) and returns: img