Summary:
Pull Request resolved: https://github.com/facebookresearch/faiss/pull/3919
These tests are passing successfully in `dev` mode during my local development when I added them but I recently noticed they are failing on contbuild which is running them in opt/mode: https://www.internalfb.com/intern/test/281475152762853/
Upon further inspection, 2 of these were from floating point comparisons which we can fix with `EXPECT_NEAR`. The another one stems from indeterminism of the results in opt mode, so we will relax the test until we figure out a way to deal with the indeterminism
Reviewed By: junjieqi
Differential Revision: D63942329
fbshipit-source-id: 60f1c0b8a0db93015cd32bf991ab983ff2d1af13
Summary:
Pull Request resolved: https://github.com/facebookresearch/faiss/pull/3849https://github.com/facebookresearch/faiss/issues/3845
Add unit tests for helper search utilities for HNSW. These utility functions live inside an anonymous namespace and each has a reference version gated behind a const bool, I refactored them so the reference version is a flag for the function which defaults to false.
If we are concerned about the performance overhead of the extra if branching (whether to use reference version or not) inside these utility functions, I'm happy to lift out the reference versions to their own functions inside the unit test
Reviewed By: junjieqi
Differential Revision: D62510014
fbshipit-source-id: b92ed4db69d125c7830da93946f1c2374fb87b08