umd-huang-lab / WAVES

Code for our paper "Benchmarking the Robustness of Image Watermarks"
51 stars 4 forks source link

cannot import ReSDPipeline from diffusers in regen.py #3

Closed holdrain closed 7 months ago

holdrain commented 7 months ago

I'm not sure if I have to install all the packages in the requirements, my diffusers version is 0.27.0

johnding1996 commented 7 months ago

Hi, thanks for your interest! Yes, for the regeneration attack, i.e., regen.py, we need a special pipeline that is not in a standard diffuser. Sorry, we did not make it clear in the readme, and we will update the instructions. Please download https://github.com/XuandongZhao/WatermarkAttacker and follow the instructions in https://github.com/XuandongZhao/WatermarkAttacker?tab=readme-ov-file#example to install the modified diffuser using command pip install -e ..

bangann commented 7 months ago

Thanks for your question, and thanks Mucong for the answer! Just to add one note here. The ReSDPipeline is a customized pipeline added to the diffusers. Please see src/diffusers/pipelines/stable_diffusion/pipeline_re_sd.py in https://github.com/XuandongZhao/WatermarkAttacker. We used the modified diffusers provided in that repo. You could also try to add this pipeline to your existing diffusers, although we don't know if any adaptation of the code is needed.