Error - Image mismatch number of tokens in prompt and number of images passe

#18
by Koshti10 - opened

Hello, I am trying to inference on this model, by using the exact script provided in Model card, But it throws the following error

raise ValueError(
ValueError: Number of image tokens in input_ids (0) different from num_images (1).

I encountered this error before the recent commits [around 17 days ago] - But then, using the argument use_fast=False in the AutoProcessor did the trick. But something has changed during recent changes. Any idea how this can be fixed? I am trying to inference on a cluster (4 * A100s [80Gbs]). I also tried setting up device_map = "auto", but nothing worked. transformers = 4.42.3

Llava Hugging Face org

Hi thanks for reporting, this is also discussed at https://huggingface.co/llava-hf/llava-v1.6-34b-hf/discussions/8#6681fdaa77540bf275b43534. I will roll back the commits for now.

Llava Hugging Face org

Update, should work now given that commits are reverted.

Sign up or log in to comment