Faiss

- Main Page
- Namespaces
- Classes
- Files

- File List

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