Stability-AI / stability-sdk

SDK for interacting with stability.ai APIs (e.g. stable diffusion inference)
https://platform.stability.ai/
MIT License
2.41k stars 339 forks source link

REST api giving wrong data #259

Closed khaven closed 8 months ago

khaven commented 8 months ago

REST api is giving wrong data on "Finish-Reason" when calling textToImage. I've called textToImage with 2 samples and 1 of the result image was blurred out but the "Finish-Reason" is giving me "SUCCESS" for both result images. I've tested this multiple times with different samples and i can confirm that the value of the "Finish-Reason" doesn't match with the result image. Most of the time it gives "SUCCESS" but the result image was blurred out. I've tested with this prompt :

"Dramatic art, amazing view, race Castanic, demonic lady full body, long hair, little horns, elegant white leather outfit. oil painting, divine proportion, highly detailed, vibrant, trending on artstation, sharp focus, photoshoot, intricate detailed, highly detailed, tera, chills run through my soul. higher quality, masterpiece, vignette, legendary rich, gorgeous"

khaven commented 8 months ago

I was using the SDXL 1.0 with no style.

pharmapsychotic commented 8 months ago

This should be fixed now, thanks for reporting!

khaven commented 8 months ago

Yes. It's working fine now. I've a question. Does credit gets reduced when the result image is blurred? I think i saw somewhere that says it doesn't but i can't find it anywhere in documentation.

khaven commented 8 months ago

I've found it. https://dreamstudio.ai/faq But it is for dreamstudio. Is it same for API?

pharmapsychotic commented 8 months ago

When a generation has finish reason FILTER (it's been detected as potentially NSFW and blurred) in the API it should not be deducting credits from your account.

khaven commented 8 months ago

Okay thank you so much! I'm closing this issue.