PaddlePaddle / PaddleMIX

Paddle Multimodal Integration and eXploration, supporting mainstream multi-modal tasks, including end-to-end large-scale multi-modal pretrain models and diffusion model toolbox. Equipped with high performance and flexibility.
Apache License 2.0
301 stars 117 forks source link

Lora训练时遇到的问题 #555

Closed 1196228233 closed 3 months ago

1196228233 commented 4 months ago

问题一:

PaddleMIX/ppdiffusers/examples/dreambooth/train_dreambooth_lora_sdxl.py:1643 会引起 memory error,建议添加代码:

del model
gc.collect()

修改后:

for i, model in enumerate(models):
    weights.append(get_state_dict(model))
    del model
    gc.collect()

问题二:

PaddleMIX/ppdiffusers/examples/dreambooth/README_sdxl.md中lora训练示例代码应该删除--report_to="wandb" \,避免报错。