AttributeError: 'LlavaNextProcessor' object has no attribute 'apply_chat_template'

#6
by 67L1 - opened

AttributeError: 'LlavaNextProcessor' object has no attribute 'apply_chat_template'

Llava Hugging Face org

You probably need to update your Transformers version, pip install --upgrade transformers

Thanks, after the update this issue was resolved. I copied the demo code directly from Model card, but the output of the model is a bit unbelievable.
image.png

I loaded the local model after downloading all the model files

Llava Hugging Face org

@67L1 Which version of transformers you have currently? We've had some issues in the latest release that should have been fixed in patch releases

4.44.2

Llava Hugging Face org

@67L1 I can't replicate the issue using code from model card, my specs are

  • transformers version: 4.44.2
  • Platform: Linux-5.4.0-166-generic-x86_64-with-glibc2.29
  • Python version: 3.8.10
  • Safetensors version: 0.4.3
  • Accelerate version: 0.33.0
  • PyTorch version (GPU?): 2.4.0+cu121 (True)
  • GPU type: NVIDIA A100-SXM4-80GB

The model checkpoint has not been changed in a while, so I don't think you have downloaded old/incorrect checkpoint. Anyway, can you make sure that the error repeats if you run the script with "hub-model-id" instead of local dir. If it doesn't, please update your local folder, Otherwise, I would need your env details to be able to help :)

Sign up or log in to comment