code: def get_files(root_path):
      res = []
      for root, dirs, files in os.walk(root_path, followlinks=True):
          for f in files:
              if f.endswith((".jpg", ".png", ".jpeg", "JPG")):
                  res.append(os.path.join(root, f))
      return res
  
file_path: PaddleSeg/Matting/ppmatting/utils/utils.py
imports: import os
  import paddle
  from urllib.parse import urlparse
  from paddleseg.utils import logger, download_pretrained_model
label_desc: Use image node_id 1 for calling a global function with example usage: get_files(root_path) and returns: res