vidore/colpali_train_set
Viewer • Updated • 119k • 4.49k • 91
How to use vidore/colpali-v1.2-merged-state_dict with ColPali:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
state_dict only)
WARNING: This repository should only be used to convert the original ColPali weights to the Hf version of Colpali.
State dict was exported from vidore/colpali-v1.2-merged. The model was loaded using the following code:
# Get the device
device = "mps"
# Define dtype
dtype_precision = torch.bfloat16
# Load the original model and state_dict
model = (
cast(
ColPali,
ColPali.from_pretrained(
"vidore/colpali-v1.2-merged",
torch_dtype=dtype_precision,
device_map=device,
),
)
.to(dtype_precision)
.eval()
)
Base model
google/paligemma-3b-pt-448