Batched inference and negative prompt

#17
by radames HF staff - opened

hi @fffiloni , I was about to send you a PR to offer you a batched inference to speedup the queue, in addition to negative prompt input and examples
However I've noticed you've added the option to add duration, very neat! however, customizing different width is not compatible with the batched pipe for image generation. Essentially we can have different prompts and negative prompts but we can't have different widths, heights, steps, scales, etc that's how the the pipeline works https://huggingface.co/docs/diffusers/api/pipelines/stable_diffusion#diffusers.StableDiffusionPipeline.__call__

You can see it in action here, if you're interested in the compromise I can send you a PR
https://huggingface.co/spaces/radames/spectrogram-to-music

The choice is hard, because users want longer music generation, in the meantime want fast generation.

What we can do, is to add a badge link to your space to let users play with both approaches, giving an alternative to skip the queue and benefit from faster inference on yours.

Also, do you think it would be possible to work on the Stable Diffusion pipeline to allow it to batch wider images ?

hi @fffiloni , that's a great point. I guess I'll close this since your Space seems to be handling the queue fine.
I'm also happy to see that you've integrated Negative prompt there! No need to link my Space I'll delete it

Great job.

radames changed discussion status to closed

Sign up or log in to comment