You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add tiling optimization and refactor tiled computation to single function (#86)
This PR contains new query optimization based on tiling the inner loop (in a manner similar to what is done for matrix-matrix product). The resulting query is 2X or more faster than the untiled version for large queries.
* Added functions `nuv_query_heap_infinite_ram_reg_blocked` and `nuv_query_heap_finite_ram_reg_blocked` that incorporate the optimization
* Implemented a new function `apply_query` that applies a query to a given set of partitions and returns `min_scores` (vector of finite min heaps)
* Added functions `query_finite_ram` and `query_infinite_ram` which are intended to be the definitive query functions. These functions use `apply_query`.
* Modified `dist_qv_finite_ram_part` to use `apply_query`
* Added dispatches to the new query functions in `ivf_flat.cc`
* Did some polishing to the flat queries and `flat_l2.cc`
* Added some concepts to facilitate function reuse for `Matrix` and `tdbMatrix`
0 commit comments