The usage is pretty simple, step by steps are on the GitHub but I agree, they should make an easier to use program. Fortunately it's not hard to setup.
For some reason the demo is down, HF keeps having such issues.
- The app takes about 30 mins~ on CPU to immunize an image, a high-end GPU a few seconds.
You can install conda and git if you don't have those on your system:
https://www.anaconda.com/download
https://git-scm.com/downloads
2a. Say you are on Windows 10-11, then in C:\Users\Documents\Apps (basically some folder in Documents you called App), where is your Windows username.
You can then type cmd.exe into the shell, this will open cmd.exe in that folder. Otherwise you will have to run "cd C:\Users\Documents\Apps" before running the script below.
Also, as stated at https://github.com/MadryLab/photoguard and the appropriate Python 3.10 will automatically install with the first conda command.
2b. Then you run in your shell e.g. cmd.exe (after installing Git and Anaconda):
git clone https://github.com/MadryLab/photoguard
conda create -n photoguard python=3.10
conda activate photoguard
cd photoguard
pip install -r requirements.txt
cd demo
python app.py
The first two command lines are only needed when installing Photoguard for the first time.
For rerunning the program in future it might be worth creating a .sh (if Linux) or .bat (if Windows) file in the installed photoguard folder and then you can just double click that to run the app. You should only include the last 2 command lines in said script if you do that.
The app by default loads to http://127.0.0.1:7860/ so once python app.py runs you just open http://127.0.0.1:7860/ in your web browser.
Follow the guide on the page that loads.
The demo script both shows the "before and after" when attempting to inverse inpaint changes into the image.
The immunization does a good job to break the img2img creating seamless integration. The demo only shows the base SD model but it applies the same affect on other models.
Basically people will struggle to use generative AI to directly manipulate your images without actually spending the effort photoshopping it.
If you have weird issues you can post them here, but expect some possible issues on older hardware which isn't really the devs' fault:
https://github.com/MadryLab/photoguard/issues