前言

因为使用Anaconda安装FAISS是最简单的一种方法,之前使用Conda(Anaconda的包管理工具)安装,老是曝出如下问题:

1
conda: error: failed to fetch repodata from 'http://repo.continuum.io/pkgs/pro/linux-64/'

解决办法:

重新去官网下载一个最新的Anaconda安装包
百度网盘下载
提取码:lebr

Ubuntu安装Anaconda

参考

安装其他包

参考

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
yirufeng@ubuntu:~/Anaconda$ conda install openblas
WARNING: The conda.compat module is deprecated and will be removed in a future release.
Collecting package metadata: done
Solving environment: done

## Package Plan ##

environment location: /home/yirufeng/anaconda3

added / updated specs:
- openblas

The following packages will be downloaded:

package | build
---------------------------|-----------------
conda-4.6.14 | py37_0 2.1 MB
libgfortran-3.0.0 | 1 281 KB
openblas-0.2.19 | 0 3.0 MB
------------------------------------------------------------
Total: 5.4 MB

The following NEW packages will be INSTALLED:

libgfortran pkgs/free/linux-64::libgfortran-3.0.0-1
openblas pkgs/free/linux-64::openblas-0.2.19-0

The following packages will be UPDATED:

c



(base) yirufeng@ubuntu:~/Anaconda$ conda install faiss-cpu -c pytorch
Collecting package metadata: done
Solving environment: done

## Package Plan ##

environment location: /home/yirufeng/anaconda3

added / updated specs:
- faiss-cpu


The following packages will be downloaded:

package | build
---------------------------|-----------------
faiss-cpu-1.5.1 | py37h6bb024c_1 879 KB pytorch
------------------------------------------------------------
Total: 879 KB

The following NEW packages will be INSTALLED:

faiss-cpu pytorch/linux-64::faiss-cpu-1.5.1-py37h6bb024c_1


Proceed ([y]/n)? y


Downloading and Extracting Packages
faiss-cpu-1.5.1 | 879 KB | ############################################## | 100%
Preparing transaction: done
Verifying transaction: done
Executing transaction: done
(base) yirufeng@ubuntu:~/Anaconda$

参考

参考