star-vector
star-vector copied to clipboard
Incorrect second argument in `_get_generation_kwargs` call in `generate_text2svg`
Description:
When using starvector.model.generate_text2svg() for text-to-SVG inference, the following line in starvector/model/models/starvector_base.py (around line 321) causes a runtime error:
generation_kwargs = self._get_generation_kwargs(
{**kwargs, 'inputs_embeds': inputs_embeds, 'attention_mask': attention_mask},
input_tokens.size(1)
)
This results in a TypeError: StarVectorBase._get_generation_kwargs() takes 2 positional arguments but 3 were given
Possible Fix: It seems to work if I remove the second argument and change the line to:
generation_kwargs = self._get_generation_kwargs({
**kwargs,
'inputs_embeds': inputs_embeds,
'attention_mask': attention_mask
})
But it always returns an empty answer on the 8b model