[diffusion] CI: minor refactor CI for less code duplication (#13905)

This commit is contained in:
Mick
2025-11-25 18:44:11 +08:00
committed by GitHub
parent 59464dbf15
commit 6f094deff0
11 changed files with 516 additions and 597 deletions

View File

@@ -409,6 +409,13 @@ def suppress_other_loggers(not_suppress_on_main_rank: bool = False):
original_levels[logger_name] = logger.level
logger.setLevel(logging.WARNING)
# Suppress verbose logging from imageio, which is triggered when saving images.
logging.getLogger("imageio").setLevel(logging.WARNING)
logging.getLogger("imageio_ffmpeg").setLevel(logging.WARNING)
# Suppress Pillow plugin import logs when app log level is DEBUG
logging.getLogger("PIL").setLevel(logging.WARNING)
logging.getLogger("PIL.Image").setLevel(logging.WARNING)
try:
yield
finally: