def get_result_trans_imgs(file_result):
    """ Read datafile holidays_images.dat and output a dictionary
    mapping queries to the set of positive results (plus a list of all
    images)"""
    gt = {}
    allnames = set()
    for line in open(file_result, "r"):
        fields = line.split()
        imname = fields[0]
        gt_results = set(fields[2::2])
        gt[imname] = gt_results
        allnames.add(imname)

    return (allnames, gt)