Handle deprecated transformer classes by DN6 · Pull Request #12517 · huggingface/diffusers (original) (raw)

What does this PR do?

transformers main has deprecated CLIPFeatureExtractor. Since a lot of pipeline configs have this object in the model index, we run into errors such as #12492 when loading those pipelines with the latest transformers.

This PR:
Introduces a remap check for transformer class names and updates to the correct class based on the installed transformer version.

Fixes # (issue)

Before submitting

Who can review?

Anyone in the community is free to review the PR once the tests have passed. Feel free to tag
members/contributors who may be interested in your PR.