def safe_mkdir_for(path):
 safe_mkdir(os.path.dirname(path), clean=False)

def safe_mkdir_for ( path ) : safe_mkdir ( os . path . dirname ( path ) , clean = False )
ensure that the parent directory for a file is present .