

def get_hits(self, hashes):
    " Return np.array of [id, delta_time, hash, time] rows\n            associated with each element in hashes array of [time, hash] rows.\n            This version has get_entry() inlined, it's about 30% faster.\n        "
    nhashes = np.shape(hashes)[0]
    hits = np.zeros(((nhashes * self.depth), 4), np.int32)
    nhits = 0
    maxtimemask = ((1 << self.maxtimebits) - 1)
    for ix in xrange(nhashes):
        time_ = hashes[ix][0]
        hash_ = hashes[ix][1]
        nids = min(self.depth, hashes.counts[hash_])
        tabvals = self.table[hash_, :nids]
        hitrows = (nhits + np.arange(nids))
        hits[(hitrows, 0)] = (tabvals >> self.maxtimebits)
        hits[(hitrows, 1)] = ((tabvals & maxtimemask) - time_)
        hits[(hitrows, 2)] = hash_
        hits[(hitrows, 3)] = time_
        nhits += nids
    hits.resize((nhits, 4))
    return hits

dataset/ETHPy150Open dpwe/audfprint/hash_table.py HashTable.get_hits/VarMisuse@105/206 `self`->`hashes`