Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

QOL Items - handle metadata issues more cleanly for SD models, Loras and embeddings #15632

Open
wants to merge 6 commits into
base: dev
Choose a base branch
from

Conversation

brendanhoar
Copy link

Description

There is a diverse set of metadata content formatting out in the wild. When sd-webui scans all of the models at startup, sometimes it does not handle encountering unexpected metadata well. These minor changes may reduce console spam and may possibly allow more models to be loaded.

e.g. there is a small fix to the safe unpickle regular expression to allow for two additional files in the zipfile that I have encountered in several embeddings. I point that out so that the additional safety review is performed.

Additional analysis of some additional problematic files, and perhaps an additional PR to follow.

100% willing to make adjustments/resubmit as requested by maintainers. I will handle rejection well.

Checklist:

All tests passed. Some deprecation warnings were generated in the face_restorers tests.

…n them

I have encountered pickled embeddings with a short byteorder file at the top-level, as well as a .data/serialization_id file.

Both load fine after allowing these files in the dataset.

I do not think it is likely adding them to the safe unpickle regular expression would be a security risk, but that's for the maintainers to decide.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant