Adjust requirements for Windows (#480)

This commit is contained in:
Lalit Pagaria 2020-10-13 17:12:24 +02:00 committed by GitHub
parent 3caaf99dcb
commit 12c4dd7b4b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 5 deletions

View File

@ -1,17 +1,22 @@
import logging
from sys import platform
from pathlib import Path
from typing import Union, List, Optional, Dict
from tqdm import tqdm
import faiss
import numpy as np
import random
from haystack import Document
from haystack.document_store.sql import SQLDocumentStore
from haystack.retriever.base import BaseRetriever
if platform != 'win32' and platform != 'cygwin':
import faiss
else:
raise ModuleNotFoundError("FAISSDocumentStore on windows platform is not supported")
logger = logging.getLogger(__name__)
class FAISSDocumentStore(SQLDocumentStore):
"""
Document store for very large scale embedding based dense retrievers like the DPR.

View File

@ -4,7 +4,6 @@ fastapi
uvicorn
gunicorn
pandas
psycopg2-binary
sklearn
elasticsearch
elastic-apm
@ -16,7 +15,7 @@ python-multipart
python-docx
sqlalchemy_utils
# for using FAISS with GPUs, install faiss-gpu
faiss-cpu
faiss-cpu; sys_platform != 'win32' and sys_platform != 'cygwin'
tika
uvloop
uvloop; sys_platform != 'win32' and sys_platform != 'cygwin'
httptools