Commit Graph

58 Commits (c6bc8c46f1decc109573978ad2b6d616b07b8eac)

Author SHA1 Message Date
Jeff Johnson f1fe029e0b Merge branch 'master' of https://github.com/facebookresearch/faiss 2020-03-29 20:07:03 -07:00
Jeff Johnson e05f773f3f CUDA 8 fixes 2020-03-29 20:07:01 -07:00
Jeff Johnson ba061ff82c CUDA 10 fixes 2020-03-30 03:01:56 +00:00
Jeff Johnson 2a36d4d8c7 fix gpu/test Makefile 2020-03-26 21:56:32 +00:00
Jeff Johnson 64dd988443 remove deleted files from template change 2020-03-25 10:57:57 -07:00
Lucas Hosseini a17a631dc3
Sync 20200323. (#1157)
* Sync 20200323.

* Bump version.

* Remove warning filter.
2020-03-24 14:06:48 +01:00
Lucas Hosseini 22b7876ef5
Facebook sync (2020-03-10) (#1136) 2020-03-10 14:24:07 +01:00
Lucas Hosseini da24fcc56e
Use intrinsics for float16 in GPU scalar quantizer. (#987) 2019-11-19 16:15:33 +01:00
Jin Hai e325c50e97 fix bugs with setNumProbes in GPUIndexIVF (#1011) 2019-11-10 07:37:06 +01:00
JinHai-CN 45639f62fa Fix GPUSQ copyto bug 2019-10-29 16:55:27 +08:00
Lucas Hosseini 36ddba9196
Facebook sync (2019-09-10) (#943)
* Facebook sync (2019-09-10)

* Fix depends Makefile target.

* Add faiss symlink for new include directives.

* Fix missing header.

* Fix tests.

* Fix Makefile.

* Update depend.

* Fix include directives spacing.
2019-09-20 18:59:10 +02:00
chck fc9856a25e Fix gpu compilation with cuda 10.1 related to #751 (#865) 2019-06-21 19:43:53 +02:00
Lucas Hosseini 3896b12c65
Facebook sync (Jun 2019) (#862)
Bugfixes:
- slow scanning of inverted lists (#836).

Features:
- add basic support for 6 new metrics in CPU `IndexFlat` and `IndexHNSW` (#848);
- add support for `IndexIDMap`/`IndexIDMap2` with binary indexes (#780).

Misc:
- throw python exception for OOM (#758);
- make `DistanceComputer` available for all random access indexes;
- gradually moving from `long` to `int64_t` for portability.
2019-06-19 15:59:06 +02:00
Lucas Hosseini ae09cabd6a
Fix Makefile in gpu/test (#843) 2019-05-29 14:32:05 +02:00
Lucas Hosseini a8118acbc5
Facebook sync (May 2019) + relicense (#838)
Changelog:

- changed license: BSD+Patents -> MIT
- propagates exceptions raised in sub-indexes of IndexShards and IndexReplicas
- support for searching several inverted lists in parallel (parallel_mode != 0)
- better support for PQ codes where nbit != 8 or 16
- IVFSpectralHash implementation: spectral hash codes inside an IVF
- 6-bit per component scalar quantizer (4 and 8 bit were already supported)
- combinations of inverted lists: HStackInvertedLists and VStackInvertedLists
- configurable number of threads for OnDiskInvertedLists prefetching (including 0=no prefetch)
- more test and demo code compatible with Python 3 (print with parentheses)
- refactored benchmark code: data loading is now in a single file
2019-05-28 16:17:22 +02:00
Matthijs Douze f443db75f3 Merge branch 'master' of https://www.github.com/facebookresearch/faiss 2019-04-08 20:26:42 -07:00
Matthijs Douze fa91c13980 take into account torch offset when getting ptr 2019-04-08 20:26:26 -07:00
Steffen Schmitz d635aa9c65 fix: gpu compilation with cuda 10.1 (#771)
The GPU compilation fails with g++ 8.3.1 and cuda 10.1
With this proposed fix the compilation works locally

Contributes to #751
2019-04-08 20:39:21 +02:00
Lucas Hosseini 7f5b22b0ff
Add conda packages metadata + tests. (#769)
+ Add conda packages metadata (now building Faiss using conda's toolchain);
+ add Dockerfile for building conda packages (for all CUDA versions);
+ add working Dockerfile building faiss on Centos7;
+ simplify GPU build;
+ avoid falling back to CPU-only version (python);
+ simplify TravisCI config;
+ update INSTALL.md;
+ add configure flag for specifying target architectures (--with-cuda-arch);
+ fix Makefile for gpu tests;
+ fix various Makefile issues;
+ remove stale file (gpu/utils/DeviceUtils.cpp).
2019-04-05 11:50:39 +02:00
Lucas Hosseini afe0fdc161
Facebook sync (Mar 2019) (#756)
Facebook sync (Mar 2019)

- MatrixStats object
- option to round coordinates during k-means optimization
- alternative option for search in HNSW
- moved stats and imbalance_factor of IndexIVF to InvertedLists object
- range search for IVFScalarQuantizer
- direct unit8 codec in ScalarQuantizer
- renamed IndexProxy to IndexReplicas and moved to main Faiss
- better support for PQ code assignment with external index
- support for IMI2x16 (4B virtual centroids!)
- support for k = 2048 search on GPU (instead of 1024)
- most CUDA mem alloc failures throw exceptions instead of terminating on an assertion
- support for renaming an ondisk invertedlists
- interrupt computations with ctrl-C in python
2019-03-29 16:32:28 +01:00
Corey J. Nolet f5feac149c For #669. Adding install target to gpu Makefile (#688) 2019-01-11 17:34:39 +01:00
Lucas Hosseini ac7005b6ef Remove CMake. (#645) 2018-12-23 18:45:16 +01:00
Huayi Zhang e23a80ebbf
Add missing `\` in gpu Makefile 2018-12-23 05:29:45 +08:00
Lucas Hosseini 323dbf3be3
Facebook sync (Dec 2018). (#660)
* Add GpuIndexBinaryFlat
* Add IndexBinaryHNSW
2018-12-19 17:48:35 +01:00
cyy 21475fb2f3 Use explicit numeric limits + add missing header (#644) 2018-11-23 14:29:58 +01:00
Lucas Hosseini 76bec0b500
Facebook sync (#573)
Features:

- automatic tracking of C++ references in Python
- non-intel platforms supported -- some functions optimized for ARM
- override nprobe for concurrent searches
- support for floating-point quantizers in binary indexes
Bug fixes:

- no more segfaults in python (I know it's the same as the first feature but it's important!)
- fix GpuIndexIVFFlat issues for float32 with 64 / 128 dims
- fix sharding of flat indexes on GPU with index_cpu_to_gpu_multiple
2018-08-30 19:38:50 +02:00
Lucas Hosseini 6880286ea0
Facebook sync (#504)
* Facebook sync

* Update swig wrappers.

* Fix comment.
2018-07-06 14:12:11 +02:00
Lucas Hosseini 1fe2872013 Rename gpu/tests to gpu/test (#481)
thanks.
2018-06-06 14:08:49 +02:00
Lucas Hosseini 57e973eae9
Fix GPU tests Makefile. (#473) 2018-06-03 20:43:02 +02:00
Lucas Hosseini cf18101f6d Refactor makefiles and add configure script (#466)
* Refactors Makefiles and add configure script.

* Give MKL higher priority in configure script.

* Clean up Linux example makefile.inc.

* Cleanup makefile.inc examples.

* Fix python clean Makefile target.

* Regen swig wrappers.

* Remove useless CUDAFLAGS variable.

* Fix python linking flags.

* Separate compile and link phase in python makefile.

* Add macro to look for swig.

* Add CUDA check in configure script.

* Cleanup make depend targets.

* Cleanup CUDA flags.

* Fix linking flags.

* Fix python GPU linking.

* Remove useless flags from python gpu module linking.

* Add check for cuda libs.

* Cleanup GPU targets.

* Clean up test target.

* Add cpu/gpu targets to python makefile.

* Clean up tutorial Makefile.

* Remove stale OS var from example makefiles.

* Clean up cuda example flags.
2018-06-02 08:35:30 +02:00
matthijs 4d440b6698 fix Makefile flags 2018-02-28 01:03:20 -08:00
Eduardo Pinho de0541c365 Add C API (#317)
* Add C API

* Add installation instructions for the C API
2018-02-26 11:23:17 +01:00
Matthijs Douze 0c482e54eb sync with FB version 2018-02-23 (#347)
- support on-disk IVF
2018-02-23 07:49:45 -08:00
Lucas Hosseini 16aed09c0f
Make tutorial examples use dynamic linkage. (#343)
* Add shared lib target for GPU version.

* Dynamically link tutorial examples.

* Add shared lib to clean target in GPU Makefile.

* Add clean target to tutorial examples Makefile.

* Minor modifications to tutorial GPU examples.
2018-02-21 15:36:29 +01:00
Matthijs Douze df2edbe3ab fix issue 320 2018-01-31 07:00:24 -07:00
matthijs 9933892ec9 sync with FB version 2017-01-09
- adding HNSW indexing method

- simultaneous search and reconstruction for IndexIVFPQ
2018-01-09 06:42:06 -08:00
matthijs fe446e41a2 bugfixes 2017-11-23 06:34:53 -08:00
matthijs 250a3d3f18 sync with FB version 2017-11-22
various bugfixes from github issues
kmean with some frozen centroids
GPU better tiling for large flat datasets
default AVX for vector ops
2017-11-22 05:11:28 -08:00
matthijs 71335194f6 sync with FB version 2017-11-22
various bugfixes from github issues
kmean with some frozen centroids
GPU better tiling for large flat datasets
default AVX for vector ops
2017-11-22 05:10:35 -08:00
matthijs d8eeceb883 sync with FB version 2017-09-08
fix index_cpu_to_gpu_multiple

fix PCA dimension
2017-09-08 04:39:41 -07:00
matthijs 54a2abb30d sync with FB version 2017-08-09 (2) 2017-08-09 11:21:50 -07:00
matthijs a5ef16db89 sync with FB version 2017-08-09 2017-08-09 11:13:51 -07:00
matthijs 8e3dc6f2b0 changed license 2017-07-30 00:18:45 -07:00
matthijs 2882e89397 forgotten 2017-07-26 03:12:49 -07:00
matthijs ca2ea5097b Sync with FB version 2017-07-16
- access GPU resources

- all Hamming distances of all sizes supported
2017-07-26 03:11:01 -07:00
matthijs 13754a74a3 fix cmakelists 2017-06-21 09:01:45 -07:00
matthijs 2d59917d33 fix GPU compile 2017-06-21 09:01:44 -07:00
matthijs 784e2facd8 Synchronization with FB version 2017-06-21
* moved most FAISS_ASSERT calls to C++ exceptions, and adjusted
  memory allocation to avoid mem leaks

* added an IndexIVFScalarQuantizer type that offers an
  intermediate compression between IVFFlat and IVFPQ

* support removal of indices in IndexIDMap / IndexFlat combination

* various fixes in GPU code
2017-06-21 09:01:06 -07:00
Boris Mansencal 678750113e add support for Nvidia GPUs with CUDA compute capability 6.1 (#110) 2017-05-31 15:52:39 +02:00
BorisMansencal 5b92eeb285 correct utils::nextHighestPowerOf2
The bit shift was done as int and not as current type (size_t for example), thus the computed next highest power of 2 was wrong on large numbers.
2017-05-06 20:36:16 +02:00