siliconflow / onediff

OneDiff: An out-of-the-box acceleration library for diffusion models.
https://github.com/siliconflow/onediff/wiki
Apache License 2.0
1.42k stars 85 forks source link

Is it possible to manually set recompile to false? #870

Closed Davin05 closed 1 month ago

Davin05 commented 1 month ago

Hi,

Thanks for making onediff possible. I am wondering if it is possible to not trigger recompile when the input is different. I am using the same unet for two different type of inferences. I use oneflow_compile to compile the unet for Type A inference. For Type B inference, I am using different call signature which has different number of tensors passed in. To save the VRAM, i dont want to load another unet. The compiled unet would automatically detect the input differences and triggered recompile on Type B. Would it be possible to set recompile to fasle during Type B? I do not need any speedup for Type B inference. Thank you!