MCPcopy Create free account
hub / github.com/TencentARC/BrushNet / export_to_gif

Function export_to_gif

src/diffusers/utils/testing_utils.py:410–422  ·  view source on GitHub ↗
(image: List[PIL.Image.Image], output_gif_path: str = None)

Source from the content-addressed store, hash-verified

408
409
410def export_to_gif(image: List[PIL.Image.Image], output_gif_path: str = None) -> str:
411 if output_gif_path is None:
412 output_gif_path = tempfile.NamedTemporaryFile(suffix=".gif").name
413
414 image[0].save(
415 output_gif_path,
416 save_all=True,
417 append_images=image[1:],
418 optimize=False,
419 duration=100,
420 loop=0,
421 )
422 return output_gif_path
423
424
425@contextmanager

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected