All Products
Search
Document Center

Platform For AI:Deploy and fine-tune Stable Diffusion V1.5 model for text-to-image generation

Last Updated:Nov 04, 2025

This topic describes how to deploy the Stable Diffusion V1.5 model and launch its WebUI to test and use the model.

Prerequisites

Create an Object Storage Service (OSS) bucket. For more information, see Create buckets in the console.

Step 1: Go to the model details page

  1. Go to the Model Gallery page.

    1. Log on to the PAI console.

    2. In the left-side navigation pane, click Workspace Management. On the workspace list page, click the name of the target workspace.

    3. In the left-side navigation pane, click Getting Started > Model Gallery to go to the Model Gallery page.

  2. On the Model Gallery page, search for and click the Stable_Diffusion_V1.5 model card to go to the model details page.

Step 2: Deploy and test the model

  1. On the model details page, click Deploy in the upper-right corner. In the Deploy panel, select a resource for deployment, such as ecs.gn6e-c12g1.3xlarge, and use the default settings for the other parameters.

  2. Click Deploy. In the Billing Reminder dialog box, click OK.

    The page automatically redirects to the Service Details page. In the Basic Information section, view the deployment status. When the Status changes to Running, the service is deployed.

  3. In the upper-right corner of the service details page, click View WEB Application to launch the WebUI.

  4. On the WebUI page, test the model's performance.

    On the Text-to-Image tab, enter the following text in the Prompt field: An eagle flying in the sky, with vast snowfields in the distance and a grassland below a snow-capped mountain. Then, click Generate. The following inference result is generated.image..png

Step 3: Fine-tune the model

Fine-tune the Stable Diffusion V1.5 model to better meet your specific business requirements.

  1. Return to the model details page and click Train in the upper-right corner.

  2. In the Train panel, expand the configuration sections to view or modify the following key settings. Use the default values for the other parameters. For more information about parameter settings, see Train models.

    Configuration Option

    Description

    Dataset Configuration

    This tutorial uses the default dataset provided by PAI. Alternatively, prepare a custom dataset by following these steps:

    1. On the model details page, prepare your training data according to the Training Data Format. You can refer to the sample dataset.image.png

    2. Upload the training data to your OSS bucket. For more information about how to upload data to an OSS bucket, see Upload files in the console.

    3. Update the training dataset. For more information, see Train models.

    Hyperparameter Configuration

    Use the default configuration for training_method: standard. Keep the default values for other parameters.

    Output Configuration

    Set the Model Output Path to an OSS bucket path. For information about how to create an OSS bucket, see Quick Start.

  3. Click Train.

    The page automatically redirects to the Task Details page.

After the training task is complete, click Deploy in the upper-right corner of the Task Details page. The deployment process is the same as described in Step 2: Deploy and test the model.