def is_xml_file(f):
    """Tries to guess if the file is a BNC xml file"""
    f.seek(0)
    line = f.readline().strip()
    while line == '':
        line = f.readline().strip()
    if line.find('<bncDoc ') != -1:
        return True
    else:
        return False