* Add Aria
---------

Co-authored-by: Cyril Vallez <cyril.vallez@gmail.com>
Co-authored-by: Arthur <48595927+ArthurZucker@users.noreply.github.com>
This commit is contained in:
Aymeric Roucher
2024-12-06 12:17:34 +01:00
committed by GitHub
parent 15ab310c3a
commit 9ad4c93536
32 changed files with 6244 additions and 7 deletions

View File

@@ -1727,6 +1727,7 @@ class GenerationTesterMixin:
num_hidden_layers = text_config.num_hidden_layers
inputs_embeds = model.get_input_embeddings()(input_ids)
max_cache_len += inputs_embeds.shape[1]
outputs = model.generate(inputs_embeds=inputs_embeds, **generation_kwargs, **inputs_dict)
# we should get `max_length` in shape, not `max_length - embeds_length`