index_int8_cpu_to_ascend

API Definition

AscendIndexInt8 *index_int8_cpu_to_ascend(std::vector<int> devices, const faiss::Index *index, const AscendClonerOptions *options = nullptr)

Function

Copies and generates an INT8 retrieval index on the Ascend based on the retrieval index resources on the CPU.

Input

std::vector<int> devices: processor ID to be configured on the NPU.

const faiss::Index *index: retrieval index resources on the CPU.

const AscendClonerOptions *options = nullptr: AscendCloneOptions resources to be configured.

Output

N/A

Return Value

Generates an INT8 retrieval index on the Ascend.

Restrictions

  • After using the index, delete the pointer to destroy the corresponding space.
  • The value of devices must be a valid processor ID.
  • The index must be a valid CPUindex pointer.