huggingface / huggingface/diffusers

Want to use "strict=False" in from_pretrained

Open
#7,608 9 comments 0 reactions 0 assignees View on GitHub
stale
Dominant language
Python
Stars
34.5k
Forks
7.3k
Avg merge
3d 3h
Merged PRs (30d)
91

Description

**What API design would you like to have changed or added to the library? Why?**
I want to add param "strict" in from_pretrained.
I want to add zerosft controlnet, but it can only implement by adding the set layers to unet class,
when I use from_pretrained, it can't use "strict=False"

**What use case would this enable or better enable? Can you give us a code example?**

def from_pretrained(cls, pretrained_model_name_or_path: Optional[Union[str, os.PathLike]], strict: bool=True, **kwargs):

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.