Skip to content

Latest commit

 

History

History
27 lines (18 loc) · 874 Bytes

README.md

File metadata and controls

27 lines (18 loc) · 874 Bytes

文图生成(Text-to-Image Generation)

import paddle
from paddlemix.appflow import Appflow

paddle.seed(42)
task = Appflow(app="text2image_generation",
               models=["stabilityai/stable-diffusion-xl-base-1.0"]
               )
prompt = "a photo of an astronaut riding a horse on mars."
result = task(prompt=prompt)['result']

效果展示

model prompt Generated Image
stabilityai/stable-diffusion-v1-5 a photo of an astronaut riding a horse on mars astronaut_rides_horse_sd
stabilityai/stable-diffusion-xl-base-1.0 a photo of an astronaut riding a horse on mars sdxl_text2image