Skip to content

Commit ec29676

Browse files
authored
[NPU] sdxl lora support NPU training (PaddlePaddle#718)
update readme for sdxl lora training
1 parent 856129e commit ec29676

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

ppdiffusers/examples/text_to_image/README_sdxl.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -233,3 +233,14 @@ for file_name in sorted(os.listdir(dir_name)):
233233
image = pipe(prompt, num_inference_steps=30, guidance_scale=7.5).images[0]
234234
image.save("pokemon_" + file_name + ".png")
235235
```
236+
237+
## NPU硬件训练
238+
请参照[tools](../../tools/README.md)进行NPU硬件Paddle安装。
239+
240+
使用NPU进行LoRA训练和推理时参考如下命令设置相应的环境变量,训练和推理运行命令可直接参照上述LoRA训练和推理命令。
241+
```bash
242+
export FLAGS_npu_storage_format=0
243+
export FLAGS_use_stride_kernel=0
244+
export FLAGS_npu_scale_aclnn=True
245+
export FLAGS_allocator_strategy=auto_growth
246+
```

0 commit comments

Comments
 (0)