cheesyFishes
commited on
Update README.md
Browse files
README.md
CHANGED
@@ -49,7 +49,7 @@ pip install -U llama-index-embeddings-huggingface
|
|
49 |
from llama_index.embeddings.huggingface import HuggingFaceEmbedding
|
50 |
|
51 |
model = HuggingFaceEmbedding(
|
52 |
-
|
53 |
device="mps",
|
54 |
trust_remote_code=True,
|
55 |
)
|
@@ -214,9 +214,9 @@ from sentence_transformers import SentenceTransformer
|
|
214 |
|
215 |
model = SentenceTransformer(
|
216 |
model_name_or_path="llamaindex/vdr-2b-v1",
|
217 |
-
device="
|
218 |
trust_remote_code=True,
|
219 |
-
# These are the recommended kwargs for the model, but change them as needed
|
220 |
model_kwargs={
|
221 |
"torch_dtype": torch.bfloat16,
|
222 |
"device_map": "cuda:0",
|
|
|
49 |
from llama_index.embeddings.huggingface import HuggingFaceEmbedding
|
50 |
|
51 |
model = HuggingFaceEmbedding(
|
52 |
+
model_name="llamaindex/vdr-2b-v1",
|
53 |
device="mps",
|
54 |
trust_remote_code=True,
|
55 |
)
|
|
|
214 |
|
215 |
model = SentenceTransformer(
|
216 |
model_name_or_path="llamaindex/vdr-2b-v1",
|
217 |
+
device="cuda",
|
218 |
trust_remote_code=True,
|
219 |
+
# These are the recommended kwargs for the model, but change them as needed if you don't have CUDA
|
220 |
model_kwargs={
|
221 |
"torch_dtype": torch.bfloat16,
|
222 |
"device_map": "cuda:0",
|