code: def mkdir(path):
      sub_dir = os.path.dirname(path)
      if not os.path.exists(sub_dir):
          os.makedirs(sub_dir)
  
file_path: PaddleSeg/tools/data/cityscapes_trainid2labelid.py
imports: import argparse
  import os
  from collections import namedtuple
  import numpy
  from PIL import Image
  from tqdm import tqdm
  from paddleseg.utils import get_image_list
label_desc: Use image node_id 2 for calling a global function with example usage: mkdir(path) without return types