Struct faiss::DirectMapAdd

struct DirectMapAdd

Thread-safe way of updating the direct_map.

Public Types

using Type = DirectMap::Type

Public Functions

DirectMapAdd(DirectMap &direct_map, size_t n, const idx_t *xids)
void add(size_t i, idx_t list_no, size_t offset)

add vector i (with id xids[i]) at list_no and offset

~DirectMapAdd()

Public Members

DirectMap &direct_map
DirectMap::Type type
size_t ntotal
size_t n
const idx_t *xids
std::vector<idx_t> all_ofs