QINCo implementation in CPU Faiss
Summary: This is a straightforward implementation of QINCo in CPU Faiss, with encoding and decoding capabilities (not training).
For this, we translate a simplified version of some torch classes:
-
tensors, restricted to 2D and int32 + float32
-
Linear and Embedding layer
Then the QINCoStep and QINCo can just be defined as C++ objects that are copy-constructable.
There is some plumbing required in the wrapping layers to support the integration. Pytroch tensors are converted to numpy for getting / setting them in C++.
Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request was exported from Phabricator. Differential Revision: D59132952
This pull request has been merged in facebookresearch/faiss@dd72e4121dc6684c6fbf289949ba4526a54d9f3b.