Faiss

- Main Page
- Namespaces
- Classes
- Files

- File List

All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends
PQScanMultiPassPrecomputed.cuh
1
2 /**
3 * Copyright (c) 2015-present, Facebook, Inc.
4 * All rights reserved.
5 *
6 * This source code is licensed under the CC-by-NC license found in the
7 * LICENSE file in the root directory of this source tree.
8 */
9
10 // Copyright 2004-present Facebook. All Rights Reserved.
11
12 #pragma once
13
14 #include "../GpuIndicesOptions.h"
15 #include "../utils/Tensor.cuh"
16 #include "../utils/NoTypeTensor.cuh"
17 #include <thrust/device_vector.h>
18
19 namespace faiss { namespace gpu {
20
21 class GpuResources;
22
23 void runPQScanMultiPassPrecomputed(Tensor<float, 2, true>& queries,
24 Tensor<float, 2, true>& precompTerm1,
25 NoTypeTensor<3, true>& precompTerm2,
26 NoTypeTensor<3, true>& precompTerm3,
27 Tensor<int, 2, true>& topQueryToCentroid,
28 bool useFloat16Lookup,
29 int bytesPerCode,
30 int numSubQuantizers,
31 int numSubQuantizerCodes,
32 thrust::device_vector<void*>& listCodes,
33 thrust::device_vector<void*>& listIndices,
34 IndicesOptions indicesOptions,
35 thrust::device_vector<int>& listLengths,
36 int maxListLength,
37 int k,
38 // output
39 Tensor<float, 2, true>& outDistances,
40 // output
41 Tensor<long, 2, true>& outIndices,
42 GpuResources* res);
43
44 } } // namespace