Merge pull request #638 from emmanuel-ferdman/main

Display class name in model error message
This commit is contained in:
Qing
2025-04-29 10:13:17 +08:00
committed by GitHub
3 changed files with 3 additions and 3 deletions

View File

@@ -201,7 +201,7 @@ class StableDiffusionBrushNetPipeline(
if safety_checker is not None and feature_extractor is None: if safety_checker is not None and feature_extractor is None:
raise ValueError( raise ValueError(
"Make sure to define a feature extractor when loading {self.__class__} if you want to use the safety" f"Make sure to define a feature extractor when loading {self.__class__} if you want to use the safety"
" checker. If you do not want to use the safety checker, you can pass `'safety_checker=None'` instead." " checker. If you do not want to use the safety checker, you can pass `'safety_checker=None'` instead."
) )

View File

@@ -286,7 +286,7 @@ class StableDiffusionInpaintPipeline(
if safety_checker is not None and feature_extractor is None: if safety_checker is not None and feature_extractor is None:
raise ValueError( raise ValueError(
"Make sure to define a feature extractor when loading {self.__class__} if you want to use the safety" f"Make sure to define a feature extractor when loading {self.__class__} if you want to use the safety"
" checker. If you do not want to use the safety checker, you can pass `'safety_checker=None'` instead." " checker. If you do not want to use the safety checker, you can pass `'safety_checker=None'` instead."
) )

View File

@@ -222,7 +222,7 @@ class StableDiffusionPowerPaintBrushNetPipeline(
if safety_checker is not None and feature_extractor is None: if safety_checker is not None and feature_extractor is None:
raise ValueError( raise ValueError(
"Make sure to define a feature extractor when loading {self.__class__} if you want to use the safety" f"Make sure to define a feature extractor when loading {self.__class__} if you want to use the safety"
" checker. If you do not want to use the safety checker, you can pass `'safety_checker=None'` instead." " checker. If you do not want to use the safety checker, you can pass `'safety_checker=None'` instead."
) )