multimodalart HF staff commited on
Commit
142aa16
1 Parent(s): 4cc5667

Wording in the code example

Browse files
Files changed (1) hide show
  1. README.md +20 -17
README.md CHANGED
@@ -65,7 +65,9 @@ aesthetic prompts. Specifically, Stable Cascade (30 inference steps) was compare
65
  steps), SDXL (50 inference steps), SDXL Turbo (1 inference step) and Würstchen v2 (30 inference steps).
66
 
67
  ## Code Example
68
- Iinstall `diffusers` from this branch while the PR is WIP.
 
 
69
  ```shell
70
  pip install git+https://github.com/kashif/diffusers.git@wuerstchen-v3
71
  ```
@@ -84,22 +86,23 @@ decoder = StableCascadeDecoderPipeline.from_pretrained("stabilityai/stable-casca
84
  prompt = "Anthropomorphic cat dressed as a pilot"
85
  negative_prompt = ""
86
 
87
- with torch.cuda.amp.autocast(dtype=dtype):
88
- prior_output = prior(
89
- prompt=prompt,
90
- height=1024,
91
- width=1024,
92
- negative_prompt=negative_prompt,
93
- guidance_scale=4.0,
94
- num_images_per_prompt=num_images_per_prompt,
95
- )
96
- decoder_output = decoder(
97
- image_embeddings=prior_output.image_embeddings,
98
- prompt=prompt,
99
- negative_prompt=negative_prompt,
100
- guidance_scale=0.0,
101
- output_type="pil",
102
- ).images
 
103
  ```
104
 
105
  ## Uses
 
65
  steps), SDXL (50 inference steps), SDXL Turbo (1 inference step) and Würstchen v2 (30 inference steps).
66
 
67
  ## Code Example
68
+
69
+ For the code below to work, you have to install `diffusers` from this branch while the PR is WIP.
70
+
71
  ```shell
72
  pip install git+https://github.com/kashif/diffusers.git@wuerstchen-v3
73
  ```
 
86
  prompt = "Anthropomorphic cat dressed as a pilot"
87
  negative_prompt = ""
88
 
89
+ prior_output = prior(
90
+ prompt=prompt,
91
+ height=1024,
92
+ width=1024,
93
+ negative_prompt=negative_prompt,
94
+ guidance_scale=4.0,
95
+ num_images_per_prompt=num_images_per_prompt,
96
+ )
97
+ decoder_output = decoder(
98
+ image_embeddings=prior_output.image_embeddings,
99
+ prompt=prompt,
100
+ negative_prompt=negative_prompt,
101
+ guidance_scale=0.0,
102
+ output_type="pil",
103
+ ).images
104
+
105
+ decoder_output
106
  ```
107
 
108
  ## Uses