def find_full_path(path_to_file):
 for (subdir, dirs, files) in os.walk('.'):
  full = os.path.relpath(os.path.join(subdir, path_to_file))
  if os.path.exists(full):
   return full

def find_full_path ( path_to_file ) : for ( subdir , dirs , files ) in os . walk ( '.' ) : full = os . path . relpath ( os . path . join ( subdir , path_to_file ) ) if os . path . exists ( full ) : return full
find the full path where we only have a relative path from somewhere in the tree .