zylon-ai / private-gpt

Interact with your documents using the power of GPT, 100% privately, no data leaks
https://docs.privategpt.dev
Apache License 2.0
52.89k stars 7.12k forks source link

Unable to run ingest.py #687

Closed gournath1 closed 5 months ago

gournath1 commented 1 year ago

Traceback (most recent call last): File "/home/g30097220/.local/lib/python3.10/site-packages/langchain/embeddings/huggingface.py", line 46, in init import sentence_transformers File "/home/g30097220/.local/lib/python3.10/site-packages/sentence_transformers/init.py", line 3, in from .datasets import SentencesDataset, ParallelSentencesDataset File "/home/g30097220/.local/lib/python3.10/site-packages/sentence_transformers/datasets/init.py", line 1, in from .DenoisingAutoEncoderDataset import DenoisingAutoEncoderDataset File "/home/g30097220/.local/lib/python3.10/site-packages/sentence_transformers/datasets/DenoisingAutoEncoderDataset.py", line 1, in from torch.utils.data import Dataset File "/home/g30097220/.local/lib/python3.10/site-packages/torch/init.py", line 229, in from torch._C import * # noqa: F403 ImportError: /home/g30097220/.local/lib/python3.10/site-packages/torch/lib/libtorch_cuda.so: undefined symbol: ncclRedOpDestroy

The above exception was the direct cause of the following exception:

ingest.py is throwing below error undefined symbol: ncclRedOpDestroy

Can someone please advise a remedy

Traceback (most recent call last): File "/home/jupyter/LocalLLM/privateGPT/privateGPT.py", line 76, in main() File "/home/jupyter/LocalLLM/privateGPT/privateGPT.py", line 26, in main embeddings = HuggingFaceEmbeddings(model_name=embeddings_model_name) File "/home/g30097220/.local/lib/python3.10/site-packages/langchain/embeddings/huggingface.py", line 49, in init raise ValueError( ValueError: Could not import sentence_transformers python package. Please install it with pip install sentence_transformers.

kyxap commented 1 year ago

have you tried to do as advised ?

ValueError: Could not import sentence_transformers python package. Please install it with pip install sentence_transformers
Freffles commented 1 year ago

got more or less the same error. And I was able to install sentence_transformers (eventually).

Traceback (most recent call last): File "d:\Media\Documents\GitHub\privateGPT\ingest.py", line 166, in main() File "d:\Media\Documents\GitHub\privateGPT\ingest.py", line 143, in main embeddings = HuggingFaceEmbeddings(model_name=embeddings_model_name) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "D:\Working\RL_Scripts\DownTT.venv\Lib\site-packages\langchain\embeddings\huggingface.py", line 54, in init raise ImportError( ImportError: Could not import sentence_transformers python package. Please install it with pip install sentence_transformers.

some1ataplace commented 1 year ago

I got this error running an old mac OS:

ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/sentencepiece/_sentencepiece.cpython-311-darwin.so, 2): Symbol not found: ____chkstk_darwin

pip3 install sentence_transformers pip3 install sentencepiece

Neither of these are working.

TyrsDev commented 1 year ago

None of the suggestions I could find in issues here worked, but doing everything within pipenv solved the problem: pipenv install -r requirements.txt pipenv run python ingest.py pipenv run python privateGPT.py