abs_path = None
for base, dirs, files in os.walk(root):
for tmp in files:
if tmp.endswith(name):
abs_path = os.path.abspath(os.path.join(base, tmp))
abs_path = None
for base, dirs, files in os.walk(root):
for tmp in files:
if tmp.endswith(name):
abs_path = os.path.abspath(os.path.join(base, tmp))