Sentence Similarity
Transformers
Safetensors
French
camembert
fill-mask
passage-retrieval
Eval Results (legacy)
text-embeddings-inference
Instructions to use antoinelouis/splade-max-camembert-base-mmarcoFR with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use antoinelouis/splade-max-camembert-base-mmarcoFR with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForMaskedLM tokenizer = AutoTokenizer.from_pretrained("antoinelouis/splade-max-camembert-base-mmarcoFR") model = AutoModelForMaskedLM.from_pretrained("antoinelouis/splade-max-camembert-base-mmarcoFR", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Error when trying the demo code
#1
by osuzdalev - opened
Hi! Very excited to try the ONLY sparse vector in French I could find.
I'm getting the following error when trying the code on the model card:
File "/Users/osuz/Library/Application Support/JetBrains/PyCharm2023.3/scratches/scratch.py", line 18, in
q_activations = torch.amax(torch.log1p(relu(q_output.logits * q_input['attention_mask'].unsqueeze(-1))), dim=1)
^^^^^^^^^^^^^^^
AttributeError: 'BaseModelOutputWithPoolingAndCrossAttentions' object has no attribute 'logits'
Any ideas?
Thanks in advance!