Earlier quoted context omitted.
Yes, the megalomania of someone who makes their code and models freely available.
StableDiffusion isn't freely available, in the "Free Software" sense. They use the highly uncommon "CreativeML Open RAIL-M License" which is a wall of text composed of weasel words describing how the software is so incredibly advanced and dangerous that despite the authors' earnest wish to do so, they cannot in good conscience make it genuinely Free Software. These people wrote a bunch of Python code that pipes image…
Stable Diffusion PR optimizes VRAM, generate 576x1280 images with 6 GB VRAM
71–80 of 151 posts
Re: Stable Diffusion PR optimizes VRAM, generate 576x1280 images with 6 GB VRAM
#72Re: Stable Diffusion PR optimizes VRAM, generate 576x1280 images with 6 GB VRAM
#73I've been using the HuggingFace diffuses repo[1] with 6GB of VRAM fine. It's well engineered, maintainable and with decent installation process. The branch in this PR[2] adds M1 Mac support with a one line patch and it runs faster than the CompVis version (1.5 iterations/sec vs 1.4 for CompVis on a 32 Gb M1 Max, I highly recommend people switching to that version for the improved flexibility. [1] https://github.com/h…
The MPS support issue for diffusers is here:
https://github.com/huggingface/diffusers/issues/292
…and it links to the relevant PyTorch issue here:
Re: Stable Diffusion PR optimizes VRAM, generate 576x1280 images with 6 GB VRAM
#74Earlier quoted context omitted.
Nah it’s just basic due diligence for releasing an open source app of this nature. Turning it off is a simple one line change, because everything is obviously named. This is not some high wall to scale. As someone that manages nsfw open source projects, this move seems fine to me. And actually kinda hilarious.
If what StableDiffusion did was ask the user something like "The prompt you entered may result in the generation of content some people find objectionable. Are you sure you want to proceed?", then I would buy your argument. As currently implemented (and the implementation took more work than a confirmation prompt would have!), it's an obvious attempt to control, rather than protect, users. They try their best to dres…
This is quite a classic HN kind of comment. Immediately assumes specific problematic intent and proposes a solution that doesn't fit the API.
Re: Stable Diffusion PR optimizes VRAM, generate 576x1280 images with 6 GB VRAM
#75Earlier quoted context omitted.
Yeah, but, when it comes to generating NSFW contents, it is illegal to distribute pornographic software in some countries, and doing so can lead to domain blockage and such (i.e. South Korea, believe or not). This is something you gotta understand. Also, if the author wanted to block NSFW contents at all, I'm pretty sure one can actually make the filter inseparable from the main network. This isn't the case here AFAI…
That makes no sense. You can draw whatever you like with Photoshop. You can search for whatever you want on Google. That doesn't make the software "NSFW", and no country will block Photoshop's domain just because someone used Photoshop to create NSFW content. Don't let people who are clearly motivated by a moralistic desire to control others hide behind BS pseudo-legal excuses.
Re: Stable Diffusion PR optimizes VRAM, generate 576x1280 images with 6 GB VRAM
#76Earlier quoted context omitted.
Yes, the megalomania of someone who makes their code and models freely available.
StableDiffusion isn't freely available, in the "Free Software" sense. They use the highly uncommon "CreativeML Open RAIL-M License" which is a wall of text composed of weasel words describing how the software is so incredibly advanced and dangerous that despite the authors' earnest wish to do so, they cannot in good conscience make it genuinely Free Software. These people wrote a bunch of Python code that pipes image…
Re: Stable Diffusion PR optimizes VRAM, generate 576x1280 images with 6 GB VRAM
#77Earlier quoted context omitted.
I am able to generate a maximum resolution of 512x768 on my 11GB 1080Ti. This seems to use almost 100% of the available RAM.
That's weird. I cap out at 512x512 on my 16GB Ampere card. Even stepping down precision doesn't help. I wonder what's different. I use it directly from Python.
I can generate a 512x512 on my 10gb 3080 no problem (or three 384x384 at a time)
Re: Stable Diffusion PR optimizes VRAM, generate 576x1280 images with 6 GB VRAM
#78Clone the original SD repo, which is what this code was built off of, and follow all the installation instructions:
https://github.com/CompVis/stable-diffusion
In that repo, replace the file ldm/modules/attention.py with this file:
https://raw.githubusercontent.com/neonsecret/stable-diffusio...
Now run a new prompt with a larger image. Note that the original model was trained on 512x512 and may lead to repetition especially if you try to increase both dimensions (this is mentioned in the SD readme) so just run with one dimension increased.
For example try the following example:
python scripts/txt2img.py --prompt "a person gardening, by claude monet" --ddim_steps 50 --seed 12000 --scale 9 --n_iter=1 --n_samples=1 --H=512 --W=1024 --skip_grid
I confirmed that if I run that command with the original attention.py, it fails due to lack of memory. With the new attention.py, it succeeds.
That said, this still uses 13GB of ram on my system.
I suppose you can check out the full repo with the updated code, which seems to have other changes, if you want to give that a try.
https://github.com/neonsecret/stable-diffusion/
I have already been using the original SD repo so I found benefit by just changing attention.py
Re: Stable Diffusion PR optimizes VRAM, generate 576x1280 images with 6 GB VRAM
#79For everyone about to comment on the garbage in the commit: It looks like the committer made their changes in the top commit, then merged the updated CompViz StableDiffusion change set on top of it for some reason. That's where the license change, rick astley image, etc come from. And yes, StableDiffusion from the original repo will rick roll you if you try to generate something that triggers its NSFW filter. Here's…
>StableDiffusion from the original repo will rick roll you if you try to generate something that triggers its NSFW filter. Just replace in scripts/txt2img.py: - x_checked_image, has_nsfw_concept = check_safety(x_samples_ddim) + x_checked_image = x_samples_ddim And be done with it.
Re: Stable Diffusion PR optimizes VRAM, generate 576x1280 images with 6 GB VRAM
#80For everyone about to comment on the garbage in the commit: It looks like the committer made their changes in the top commit, then merged the updated CompViz StableDiffusion change set on top of it for some reason. That's where the license change, rick astley image, etc come from. And yes, StableDiffusion from the original repo will rick roll you if you try to generate something that triggers its NSFW filter. Here's…
> And yes, StableDiffusion from the original repo will rick roll you if you try to generate something that triggers its NSFW filter. It goes without saying that the authors of a piece of software have the right to make the software do whatever they want, but that shouldn't stop us from recognizing that AI engineers are starting to act like megalomaniac overseers who consider it part of their mission to steer humanity…