code: def ensure_directory_exists(filename):
      """Build filename's path if it does not already exists."""
      dirname = os.path.dirname(filename)
      os.makedirs(dirname, exist_ok=True)
  
imports: import os
  import random
  import sys
  import numpy
  import torch
  from megatron import update_num_microbatches
  from megatron.core import mpu, tensor_parallel
  from .global_vars import get_args
  from .utils import unwrap_model, print_rank_0
label_desc: Use image node_id 4 for calling a global function with example usage: ensure_directory_exists(filename) without return types