| 1 |
/* |
| 2 |
* Copyright (c) Meta Platforms, Inc. and affiliates. |
| 3 |
* |
| 4 |
* This source code is licensed under the MIT license found in the |
| 5 |
* LICENSE file in the root directory of this source tree. |
| 6 |
*/ |
| 7 |
|
| 8 |
#include <faiss/perf_tests/utils.h> |
| 9 |
namespace faiss::perf_tests { |
| 10 |
std::map<std::string, faiss::ScalarQuantizer::QuantizerType> sq_types() { |
| 11 |
static std::map<std::string, faiss::ScalarQuantizer::QuantizerType> |
| 12 |
sq_types = { |
| 13 |
{"QT_8bit", faiss::ScalarQuantizer::QT_8bit}, |
| 14 |
{"QT_4bit", faiss::ScalarQuantizer::QT_4bit}, |
| 15 |
{"QT_8bit_uniform", |
| 16 |
faiss::ScalarQuantizer::QT_8bit_uniform}, |
| 17 |
{"QT_4bit_uniform", |
| 18 |
faiss::ScalarQuantizer::QT_4bit_uniform}, |
| 19 |
{"QT_fp16", faiss::ScalarQuantizer::QT_fp16}, |
| 20 |
{"QT_8bit_direct", faiss::ScalarQuantizer::QT_8bit_direct}, |
| 21 |
{"QT_6bit", faiss::ScalarQuantizer::QT_6bit}, |
| 22 |
{"QT_bf16", faiss::ScalarQuantizer::QT_bf16}, |
| 23 |
{"QT_8bit_direct_signed", |
| 24 |
faiss::ScalarQuantizer::QT_8bit_direct_signed}}; |
| 25 |
return sq_types; |
| 26 |
} |
| 27 |
} // namespace faiss::perf_tests |