-
-
Notifications
You must be signed in to change notification settings - Fork 207
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add_to_index uses too much GPU RAM and crashes #205
Comments
I am facing this issue even with just 100 documents trying to use just
|
Hey, apologies for the very late answer. This seems to be an issue with the torch k-means implementation being far too hungry in some cases. Working on a fix now. |
+1, I described my problem in #247 |
I'm having this error when trying to add documents to an index created with RAGatouille (
|
Hi there,
I am implementing Ragatouille at scale for a RAG model project. I am running the add_to_index() method sequentially but I keep running into memory issues with my GPU with 16 GB RAM. Does the add_to_index() method use GPU RAM or am I implementing something incorrectly?
Is there a way to optimize my GPU usage? Can I also run only on CPU?
Thanks.
Martin
Provided code:
from ragatouille import RAGPretrainedModel
RAG = RAGPretrainedModel.from_pretrained("colbert-ir/colbertv2.0")
RAG.index(
collection=[file_content],
document_metadatas=[{'source': 'initial_data.txt', 'page': 0}],
document_ids=[str(uuid.uuid4())],
index_name="test3",
split_documents=True,
max_document_length=300,
#use_faiss=True
)
for _ in range(10):
RAG.add_to_index(
new_collection=all_splits_rgt,
new_document_metadatas=rgt_metadatas,
new_document_ids=[str(uuid.uuid4()) for _ in range(len(all_splits_rgt))],
#index_name="test1",
#new_split_documents=True,
#new_max_document_length=300,
#use_faiss=True
)
retriever_advanced_text = RAG_redone.as_langchain_retriever(k=10)
The text was updated successfully, but these errors were encountered: