Team Ai
Datasetpublic

artdwn/stable-diffusion-backup

Stable Diffusion web UI A browser interface based on Gradio library for Stable Diffusion. Features Detailed feature showcase with images: Original txt2img and img2img modes One click install and run script (but you still must install python and git) Outpainting Inpainting Color Sketch Prompt Matrix Stable Diffusion Upscale Attention, specify parts of text that the model should pay more attention to a man in a ((tuxedo)) - will pay more attention to tuxedo a man… See the full description on the dataset page: https://huggingface.co/datasets/artdwn/stable-diffusion-backup.

sourceHugging Faceupdated 3y agoView on Hugging Face
1likes1.1kdownloads
imageMaskFix.js44 linesDownload Raw Back to javascript
1/**2 * temporary fix for https://github.com/AUTOMATIC1111/stable-diffusion-webui/issues/6683 * @see https://github.com/gradio-app/gradio/issues/17214 */5function imageMaskResize() {6    const canvases = gradioApp().querySelectorAll('#img2maskimg .touch-none canvas');7    if (!canvases.length) {8        window.removeEventListener('resize', imageMaskResize);9        return;10    }11 12    const wrapper = canvases[0].closest('.touch-none');13    const previewImage = wrapper.previousElementSibling;14 15    if (!previewImage.complete) {16        previewImage.addEventListener('load', imageMaskResize);17        return;18    }19 20    const w = previewImage.width;21    const h = previewImage.height;22    const nw = previewImage.naturalWidth;23    const nh = previewImage.naturalHeight;24    const portrait = nh > nw;25 26    const wW = Math.min(w, portrait ? h / nh * nw : w / nw * nw);27    const wH = Math.min(h, portrait ? h / nh * nh : w / nw * nh);28 29    wrapper.style.width = `${wW}px`;30    wrapper.style.height = `${wH}px`;31    wrapper.style.left = `0px`;32    wrapper.style.top = `0px`;33 34    canvases.forEach(c => {35        c.style.width = c.style.height = '';36        c.style.maxWidth = '100%';37        c.style.maxHeight = '100%';38        c.style.objectFit = 'contain';39    });40}41 42onAfterUiUpdate(imageMaskResize);43window.addEventListener('resize', imageMaskResize);44