Skip to content

"AutoProcessor.from_pretrained" cannot run in distributed environments after v4.56.0 #40731

@erikchwang

Description

@erikchwang

Python 3.12

transformers>=4.56.0

Running "AutoProcessor.from_pretrained" (e.g. AutoProcessor.from_pretrained('Qwen/Qwen2.5-VL-7B-Instruct')) in a ray or torchrun environment causes error:

OSError: Can't load image processor for 'Qwen/Qwen2.5-VL-7B-Instruct'. If you were trying to load it from '[https://huggingface.co/models'](https://huggingface.co/models%27), make sure you don't have a local directory with the same name.

This issue happens after v4.56.0.

Downgrading to v4.55.4 can avoid this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions