api_sparrow_ocr / download_model.py
Frederic-CellNum's picture
Create download_model.py
82aed82 verified
raw
history blame contribute delete
367 Bytes
from transformers import Qwen2VLForConditionalGeneration, AutoProcessor
print("Téléchargement du processor...")
AutoProcessor.from_pretrained("Qwen/Qwen2-VL-7B-Instruct")
print("Téléchargement du modèle...")
Qwen2VLForConditionalGeneration.from_pretrained(
"Qwen/Qwen2-VL-7B-Instruct",
torch_dtype="auto"
)
print("Modèle téléchargé avec succès!")