当前位置:   article > 正文

diffusers-AutoPipline_from diffusers import autopipelinefortext2image

from diffusers import autopipelinefortext2image

https://huggingface.co/docs/diffusers/tutorials/autopipelineicon-default.png?t=N7T8https://huggingface.co/docs/diffusers/tutorials/autopipelineAutoPipeline会自动检测要使用的正确流程类,这样可以更轻松地加载与任务相对应的检查点,而无需知道具体的流程类名称。

1.choose an autopipeline for your task

  1. from diffusers import AutoPipelineForText2Image
  2. import torch
  3. pipeline = AutoPipelineForText2Image.from_pretrained(
  4. "runwayml/stable-diffusion-v1-5", torch_dtype=torch.float16, use_safetensors=True
  5. ).to("cud
声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/神奇cpp/article/detail/735518
推荐阅读
相关标签
  

闽ICP备14008679号