Update README.md
Browse files
README.md
CHANGED
|
@@ -112,7 +112,7 @@ from olmocr.data.renderpdf import render_pdf_to_base64png
|
|
| 112 |
from olmocr.prompts import build_no_anchoring_v4_yaml_prompt
|
| 113 |
|
| 114 |
# Initialize the model
|
| 115 |
-
model = Qwen2_5_VLForConditionalGeneration.from_pretrained("allenai/olmOCR-2-7B-1025",
|
| 116 |
processor = AutoProcessor.from_pretrained("Qwen/Qwen2.5-VL-7B-Instruct")
|
| 117 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
| 118 |
model.to(device)
|
|
|
|
| 112 |
from olmocr.prompts import build_no_anchoring_v4_yaml_prompt
|
| 113 |
|
| 114 |
# Initialize the model
|
| 115 |
+
model = Qwen2_5_VLForConditionalGeneration.from_pretrained("allenai/olmOCR-2-7B-1025-FP8", device_map="auto").eval()
|
| 116 |
processor = AutoProcessor.from_pretrained("Qwen/Qwen2.5-VL-7B-Instruct")
|
| 117 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
| 118 |
model.to(device)
|