Try it out | View on Replicate
This repo contains a modified implementation of the example code provided in the Red-Teaming the Stable Diffusion Safety Filter paper.
Note If you just wanna try the model out or run it in production, see the link above.
This model is packaged as a Cog model, a tool to packages machine learning models as standard containers.
First, download Cog on your system. Then, download the pre-trained weights with your Hugging Face auth token:
cog run script/download-weights <your-hugging-face-auth-token>
Once setup, you can run predictions:
cog predict -i image=@/path/to/image.jpg