faiss
faiss copied to clipboard
There appear to be 1 leaked semaphore objects to clean up at shutdown
Summary
Platform
OS: MacOS 10.15 8 GB
Faiss version:
Installed from:
Faiss compilation options:
Running on:
- [ x] CPU
- [ ] GPU
Interface:
- [ ] C++
- [x ] Python
Reproduction instructions
model = SentenceTransformer('all-MiniLM-L6-v2', device='cpu') # Force CPU usage
print(f"Encoding query: {query}")
print(f"Size of RAG data: {len(rag_data)}")
import sys
print(f"Memory usage: {sys.getsizeof(rag_data)} bytes")
query_embedding = model.encode(query, show_progress_bar=False)
Size of RAG data: 272
Memory usage: 2520 bytes
/opt/miniconda3/envs/wapi/lib/python3.9/multiprocessing/resource_tracker.py:216: UserWarning: resource_tracker: There appear to be 1 leaked semaphore objects to clean up at shutdown
FYI Memory usage: 83.7%
Any help would be appreciated!
Hi @jakubLangr, can you clarify where faiss comes into play here?
This issue is stale because it has been open for 7 days with no activity.
Apologies, upon investigation it doesn't.
@jakubLangr I had a similar problem, I just imported faiss and didn't do anything. How did you solve it
import faiss
import torch
from colpali_engine.models import ColQwen2
model_name = "vidore/colqwen2-v0.1"
model = ColQwen2.from_pretrained(
model_name,
torch_dtype=torch.bfloat16,
device_map="mps", # or "mps" if on Apple Silicon
).eval()
UserWarning: resource_tracker: There appear to be 1 leaked semaphore objects to clean up at shutdown
warnings.warn('resource_tracker: There appear to be %d '
Process finished with exit code 139 (interrupted by signal 11:SIGSEGV)