AnswerDotAI / RAGatouille

Easily use and train state of the art late-interaction retrieval methods (ColBERT) in any RAG pipeline. Designed for modularity and ease-of-use, backed by research.
Apache License 2.0
3.08k stars 210 forks source link

Size Mismatch while training answerai-colbert-smallv1 #257

Closed Harrolee closed 1 month ago

Harrolee commented 1 month ago

Hi!

Awesome library. You're a champ, Ben.

The following error appeared while training colbert-small:

RuntimeError: Error(s) in loading state_dict for HF_ColBERT:
        size mismatch for linear.weight: copying a param with shape torch.Size([96, 384]) from checkpoint, the shape in current model is torch.Size([128, 384]).
        You may consider adding `ignore_mismatched_sizes=True` in the model `from_pretrained` method.

Does Ragatouille support training answerai-colbert-smallv1? I'm on a macbook with an M1. Is this an mps vs cuda issue?

Harrolee commented 1 month ago

I found this note in the Ragatouille basic training notebook: Please note: Training can currently only be ran on GPU, and will error out if using CPU/MPS! Training is also currently not functional on Google Closing this issue. 👋