rom_pretrained(model_id)
prompt = "sailing ship in storm by Leonardo da Vinci"
image = pipeline(prompt).images[0] To export the pipeline in the ONNX format and use it later for inference, use the optimum-cli export command:   Copied optimum-cli export onnx --model stabilityai/stable-diffusion-xl-base-1.0 --task stable-diffusion-xl sd_xl_onnx/ SDXL in the ONNX format is supported for text-to-image and image-to-image.
