microsoft / SPTAG

A distributed approximate nearest neighborhood search (ANN) library which provides a high quality vector index build, search and distributed online serving toolkits for large scale vector search scenario.
MIT License
4.83k stars 580 forks source link

Add GPU KNN to Generate Truth #336

Closed caijiediego closed 2 years ago

caijiediego commented 2 years ago

Add GPU KNN branch to Generate Truth

Code changes including:

  1. Add Implementation of GPU KNN kernel code to KNN.hxx file
  2. Adding TruthSet.cpp. To save implementation of Generate Truth to avoid compiling issue.
  3. Relocate the Point to GPUKNNDistance.hxx In order to detach GPU KNN generation from GPU Index build
  4. Add TransposedPoint Structure to avoid GPU bank conflict
  5. Recover functions for Point Structure in ThreapHeap from deprecated
  6. Reduce Thread Number per Block from 64 to 32, in order to suit more GPU with limited shared memory size
  7. Fixed a minor bug for some version of Windows compiler in [cuda_unit_tests.cu]

Cmake Build Change:

  1. Update Arch to sm_70, sm_75, sm_80 in cmake
  2. Modified CmakeList to suit submodule zstd