code: def read_img(img_path):
      _img = Image.open(img_path).convert("RGB")  # return is RGB pic
      return _img
  
file_path: insightface/reconstruction/ostec/external/graphonomy/FaceHairMask/graphonomy_inference.py
imports: import cv2
  import torch
  import timeit
  import numpy
  from PIL import Image
  import torch.nn.functional
  from torch.autograd import Variable
  from torchvision import transforms
  from FaceHairMask import graph
  from FaceHairMask import graphonomy_process
label_desc: Use image node_id 6 for calling a global function with example usage: read_img(img_path) and returns: _img