Rubbrband detects deformities in your images generated by Stable Diffusion at scale.
pip install rubbrband
import rubbrband
rubbrband.init("YOUR_API_KEY")
rubbrband.upload(image="https://example.com/image.png", prompt="Prompt used to generate image")
- Using a URL
rubbrband.upload(image="https://example.com/image.png", prompt="Prompt used to generate image")
- Using a PIL Image
from PIL import Image
rubbrband.upload(image=Image.open("/path/to/image.png"), prompt="Prompt used to generate image")
- Using a path
rubbrband.upload(image="/path/to/image.png", prompt="Prompt used to generate image")
- Using a context manager
with open("/path/to/image.png", "rb") as f:
rubbrband.upload(image=f, prompt="Prompt used to generate image")
filename = rubbrband.upload(image="/path/to/image.png", prompt="Prompt used to generate image")
evaluation = rubbrband.get_image_metadata(filename)