-
I was trying to follow the documentation from https://github.com/castorini/pyserini#dense-indexes . On MacOS 12.6 Monterey, when running the script below I get a Segmentation fault error. python -m pyserini.encode \
input --corpus data/collections/simple_cacm_corpus.json \
--fields text \
output --embeddings embeddings/small-dense-1668560951 \
encoder --encoder castorini/tct_colbert-v2-hnp-msmarco \
--fields text \
--batch 8 \
--fp16 returns |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 17 replies
-
Faiss dense retrieval is memory intensive. How much RAM do you have on your machine? |
Beta Was this translation helpful? Give feedback.
-
Can you please note the resolution on the GitHub discussion ticket so we
can close it?
…-Jimmy
On 11/16/22 8:07 AM, Victor Paraschiv wrote:
I had |faiss-cpu| installed via pip. Interestingly tevatron was working
fine.
Run |conda install faiss-cpu -c pytorch| and solved the problem.
Thanks for this.
—
Reply to this email directly, view it on GitHub
<#1346 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AACMT3NLDEQG3W54KB5UMILWITL77ANCNFSM6AAAAAASBUHOTM>.
You are receiving this because you commented.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
For CPU only machines adding I installed all dependencies via I managed to successfully run it on both python 3.8 and 3.9. |
Beta Was this translation helpful? Give feedback.
For CPU only machines adding
--device cpu
seems to fix the problem. Even when all packages are installed as for CPU only for some reason, pytorch/ torch/ faiss forces the use of some CUDA enabled dependencies.I installed all dependencies via
pip
directly and it works. No need to reach out to anaconda. In my case that kept throwing 'Segmentation fault 11' errors.I managed to successfully run it on both python 3.8 and 3.9.