def binned_bitsets_from_list( list=[] ):
    """Read a list into a dictionary of bitsets"""
    last_chrom = None
    last_bitset = None
    bitsets = dict()
    for l in list:
        chrom = l[0]
        if chrom != last_chrom:
            if chrom not in bitsets:
                bitsets[chrom] = BinnedBitSet(MAX)
            last_chrom = chrom
            last_bitset = bitsets[chrom]
        start, end = int( l[1] ), int( l[2] )
        last_bitset.set_range( start, end - start )
    return bitsets
Read a list into a dictionary of bitsets