Update README.md
Browse files
README.md
CHANGED
|
@@ -41,11 +41,11 @@ from transformers import AutoProcessor, Florence2ForConditionalGeneration, BitsA
|
|
| 41 |
|
| 42 |
|
| 43 |
model = Florence2ForConditionalGeneration.from_pretrained(
|
| 44 |
-
"florence-community/Florence-2-
|
| 45 |
dtype=torch.bfloat16,
|
| 46 |
device_map="auto",
|
| 47 |
)
|
| 48 |
-
processor = AutoProcessor.from_pretrained("florence-community/Florence-2-
|
| 49 |
|
| 50 |
url = "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/transformers/tasks/car.jpg?download=true"
|
| 51 |
image = Image.open(requests.get(url, stream=True).raw).convert("RGB")
|
|
|
|
| 41 |
|
| 42 |
|
| 43 |
model = Florence2ForConditionalGeneration.from_pretrained(
|
| 44 |
+
"florence-community/Florence-2-base",
|
| 45 |
dtype=torch.bfloat16,
|
| 46 |
device_map="auto",
|
| 47 |
)
|
| 48 |
+
processor = AutoProcessor.from_pretrained("florence-community/Florence-2-base")
|
| 49 |
|
| 50 |
url = "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/transformers/tasks/car.jpg?download=true"
|
| 51 |
image = Image.open(requests.get(url, stream=True).raw).convert("RGB")
|