def annotate_variants_extract(args, conn, metadata, col_names, col_types, col_ops, col_idxs):
    """
    Populate a new, user-defined column in the variants
    table based on the value(s) from a specific column.
    in the annotation file.
    """
    def summarize_hits(hits):
        hit_list = get_hit_list(hits, col_idxs, args)
        if hit_list == []: return []
        vals = []
        for idx, op in enumerate(col_ops):
            # more than one overlap, must summarize
            try:
                val = op_funcs[op](hit_list[idx], col_types[idx])
            except __HOLE__:
                val = None
            if not 'list' in op:
                vals.append(fix_val(val, col_types[idx]))
            else:
                # already stringed it in list/uniq_list so don't check type
                vals.append(val)

        return vals

    return _annotate_variants(args, conn, metadata, summarize_hits,
                              col_names, col_types, col_ops)
dataset/ETHPy150Open arq5x/gemini/gemini/gemini_annotate.py/annotate_variants_extract