JittorRepos / JDiffusion

JDiffusion is a diffusion model library for generating images or videos based on Diffusers and Jittor.
Apache License 2.0
250 stars 4 forks source link

to_out.0 in lora doesn't work #4

Closed gaoren002 closed 2 months ago

gaoren002 commented 2 months ago

when Lora model passed to peft(0.10.0) ,peft dosen't solve to_out.0 this layer, so we can't train this layer. The details are, to_out is a Sequential, the code in peft try to set attribute 0 of the sequential, but actually, it only set an new attribute for this Sequential, but real "0"layer is in the layers attribute of sequential is not replaced by lora.

To solve this problem, I can only modify the peft to adapt the model passed by jdiffusion.

gaoren002 commented 2 months ago

bug has been fixed in jittor repo