2017-02-22 23:26:44 +01:00
|
|
|
/**
|
2019-05-28 16:17:22 +02:00
|
|
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
2017-02-22 23:26:44 +01:00
|
|
|
*
|
2019-05-28 16:17:22 +02:00
|
|
|
* This source code is licensed under the MIT license found in the
|
2017-02-22 23:26:44 +01:00
|
|
|
* LICENSE file in the root directory of this source tree.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
2019-09-20 18:59:10 +02:00
|
|
|
#include <faiss/Index.h>
|
|
|
|
#include <faiss/AutoTune.h>
|
2017-02-22 23:26:44 +01:00
|
|
|
|
|
|
|
namespace faiss { namespace gpu {
|
|
|
|
|
|
|
|
|
|
|
|
/// parameter space and setters for GPU indexes
|
|
|
|
struct GpuParameterSpace: faiss::ParameterSpace {
|
|
|
|
/// initialize with reasonable parameters for the index
|
|
|
|
void initialize (const faiss::Index * index) override;
|
|
|
|
|
|
|
|
/// set a combination of parameters on an index
|
|
|
|
void set_index_parameter (
|
|
|
|
faiss::Index * index, const std::string & name,
|
|
|
|
double val) const override;
|
|
|
|
};
|
|
|
|
|
|
|
|
} } // namespace
|