diff --git a/src/diffusers/loaders.py b/src/diffusers/loaders.py index a0be20c54361..525bb446b77e 100644 --- a/src/diffusers/loaders.py +++ b/src/diffusers/loaders.py @@ -177,7 +177,7 @@ def load_attn_procs(self, pretrained_model_name_or_path_or_dict: Union[str, Dict if use_safetensors and not is_safetensors_available(): raise ValueError( - "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetenstors" + "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetensors" ) allow_pickle = False @@ -589,7 +589,7 @@ def load_textual_inversion( if use_safetensors and not is_safetensors_available(): raise ValueError( - "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetenstors" + "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetensors" ) allow_pickle = False @@ -806,7 +806,7 @@ def load_lora_weights(self, pretrained_model_name_or_path_or_dict: Union[str, Di if use_safetensors and not is_safetensors_available(): raise ValueError( - "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetenstors" + "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetensors" ) allow_pickle = False @@ -1054,7 +1054,7 @@ def _load_text_encoder_attn_procs( if use_safetensors and not is_safetensors_available(): raise ValueError( - "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetenstors" + "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetensors" ) allow_pickle = False diff --git a/src/diffusers/models/modeling_utils.py b/src/diffusers/models/modeling_utils.py index cc8df3fe6d69..1fa96514c0a9 100644 --- a/src/diffusers/models/modeling_utils.py +++ b/src/diffusers/models/modeling_utils.py @@ -456,7 +456,7 @@ def from_pretrained(cls, pretrained_model_name_or_path: Optional[Union[str, os.P if use_safetensors and not is_safetensors_available(): raise ValueError( - "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetenstors" + "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetensors" ) allow_pickle = False diff --git a/src/diffusers/pipelines/pipeline_utils.py b/src/diffusers/pipelines/pipeline_utils.py index 734af819c852..87c0f711a30c 100644 --- a/src/diffusers/pipelines/pipeline_utils.py +++ b/src/diffusers/pipelines/pipeline_utils.py @@ -204,7 +204,7 @@ def variant_compatible_siblings(filenames, variant=None) -> Union[List[os.PathLi transformers_index_format = r"\d{5}-of-\d{5}" if variant is not None: - # `diffusion_pytorch_model.fp16.bin` as well as `model.fp16-00001-of-00002.safetenstors` + # `diffusion_pytorch_model.fp16.bin` as well as `model.fp16-00001-of-00002.safetensors` variant_file_re = re.compile( rf"({'|'.join(weight_prefixes)})\.({variant}|{variant}-{transformers_index_format})\.({'|'.join(weight_suffixs)})$" ) @@ -213,7 +213,7 @@ def variant_compatible_siblings(filenames, variant=None) -> Union[List[os.PathLi rf"({'|'.join(weight_prefixes)})\.({'|'.join(weight_suffixs)})\.index\.{variant}\.json$" ) - # `diffusion_pytorch_model.bin` as well as `model-00001-of-00002.safetenstors` + # `diffusion_pytorch_model.bin` as well as `model-00001-of-00002.safetensors` non_variant_file_re = re.compile( rf"({'|'.join(weight_prefixes)})(-{transformers_index_format})?\.({'|'.join(weight_suffixs)})$" ) @@ -1168,7 +1168,7 @@ def download(cls, pretrained_model_name, **kwargs) -> Union[str, os.PathLike]: if use_safetensors and not is_safetensors_available(): raise ValueError( - "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetenstors" + "`use_safetensors`=True but safetensors is not installed. Please install safetensors with `pip install safetensors" ) allow_pickle = False