Safetensors
English
French
vidore
manu commited on
Commit
df45297
1 Parent(s): 8e13d1f

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +5 -5
README.md CHANGED
@@ -47,18 +47,18 @@ from tqdm import tqdm
47
  from transformers import AutoProcessor
48
  from PIL import Image
49
 
50
- from colpali_engine.models.paligemma_colbert_architecture import ColPali
51
  from colpali_engine.trainer.retrieval_evaluator import CustomEvaluator
52
- from colpali_engine.utils.colpali_processing_utils import process_images, process_queries
53
  from colpali_engine.utils.image_from_page_utils import load_from_dataset
54
 
55
 
56
  def main() -> None:
57
- """Example script to run inference with ColPali"""
58
 
59
  # Load model
60
- model_name = "vidore/colpali"
61
- model = ColPali.from_pretrained("google/paligemma-3b-mix-448", torch_dtype=torch.bfloat16, device_map="cuda").eval()
62
  model.load_adapter(model_name)
63
  processor = AutoProcessor.from_pretrained(model_name)
64
 
 
47
  from transformers import AutoProcessor
48
  from PIL import Image
49
 
50
+ from colpali_engine.models.idefics_colbert_architecture import ColIdefics
51
  from colpali_engine.trainer.retrieval_evaluator import CustomEvaluator
52
+ from colpali_engine.utils.colidefics_processing_utils import process_images, process_queries
53
  from colpali_engine.utils.image_from_page_utils import load_from_dataset
54
 
55
 
56
  def main() -> None:
57
+ """Example script to run inference with ColIdefics"""
58
 
59
  # Load model
60
+ model_name = "vidore/colidefics"
61
+ model = ColIdefics.from_pretrained("HuggingFaceM4/idefics2-8b", torch_dtype=torch.bfloat16, device_map="cuda").eval()
62
  model.load_adapter(model_name)
63
  processor = AutoProcessor.from_pretrained(model_name)
64