r/StableDiffusion • u/Meronoth • Aug 22 '22
Discussion How do I run Stable Diffusion and sharing FAQs
I see a lot of people asking the same questions. This is just an attempt to get some info in one place for newbies, anyone else is welcome to contribute or make an actual FAQ. Please comment additional help!
This thread won't be updated anymore, check out the wiki instead!. Feel free to keep discussion going below! Thanks for the great response everyone (and the awards kind strangers)
How do I run it on my PC?
New updated guidehere, will also be posted in the comments (thanks 4chan).You need no programming experience, it's all spelled out.- Check out the guide on the wiki now!
How do I run it without a PC? / My PC can't run it
- https://beta.dreamstudio.ai - you start with 200 standard generations free (NSFW Filter)
- Google Colab - (non functional until release) run a limited instance on Google's servers. Make sure to set GPU Runtime (NSFW Filter)
- Larger list of publicly accessible Stable Diffusion models
How do I remove the NSFW Filter
- For the main repo
- Using HuggingFace Diffusers
- DreamStudio removed the NSFW filter option, no removing for now
Will it run on my machine?
- A Nvidia GPU with 4 GB or more RAM is required
- AMD is confirmed to work with tweaking but is unsupported
- M1 chips are to be supported in the future
I'm confused, why are people talking about a release
- "Weights" are the secret sauce in the model.
We're operating on old weights right now, and the new weights are what we're waiting for. Release 2 PM EST - See top edit for link to the new weights
- The full release was 8/23
My image sucks / I'm not getting what I want / etc
- Style guides now exist and are great help
- Stable Diffusion is much more verbose than competitors. Prompt engineering is powerful. Try looking for images on this sub you like and tweaking the prompt to get a feel for how it works
- Try looking around for phrases the AI will really listen to
My folder name is too long / file can't be made
- There is a soft limit on your prompt length due to the character limit for folder names
- In optimized_txt2img.py change
sample_path = os.path.join(outpath, "_".join(opt.prompt.split()))[:255]to sample_path = os.path.join(outpath, "_")and replace "_" with the desired name. This will write all prompts to the same folder but the cap is removed
How to run Img2Img?
- Use the same setup as the guide linked above, but run the command
python optimizedSD/optimized_img2img.py --prompt "prompt" --init-img ~/input/input.jpg --strength 0.8 --n_iter 2 --n_samples 2 --H 512--W 512 - Where "prompt" is your prompt, "input.jpg" is your input image, and "strength" is adjustable
- This can be customized with similar arguments as text2img
Can I see what setting I used / I want better filenames
- TapuCosmo made a script to change the filenames
- Use at your own risk. Download is from a discord attachment
11
u/Meronoth Aug 22 '22
Link to guide
21
u/jonplackett Aug 22 '22
Does anyone else get an error like this? I thought we 11GB vram I'd be able to generate pretty high res images, but it freaks out if i ask for anything over 512x512
RuntimeError: CUDA out of memory. Tried to allocate 3.66 GiB (GPU 0; 11.00 GiB total capacity; 5.87 GiB already allocated; 2.46 GiB free; 6.59 GiB reserved in total by PyTorch)
12
u/UnstableElusion Aug 22 '22 edited Aug 22 '22
Most AMD users with consumer-grade cards are fucked.
No ROCm support is coming for Navi 10 chips (RX 5700 XT), according to this comment: https://github.com/RadeonOpenCompute/ROCm/issues/1714#issuecomment-1128327143
Unofficial black magic is available: https://github.com/xuhuisheng/rocm-build/tree/master/navi10
I haven't tried building this yet, but it seems to be the only hope we have. (pytorch 1.12.0 is outdated but can run SD)
EDIT: From the official site:
Hopefully the developers can offer us some alternative in the near future.
Otherwise you can try running it in CPU mode, which is extremely slow. My comment here could be helpful: https://old.reddit.com/r/StableDiffusion/comments/wt023b/tweet_from_emostaque_we_have_got_it_down_to_21_gb/il1vfa2/
5
u/romaoplays Aug 22 '22
Any help on how to run img2img?
4
u/74qwewq5rew3 Aug 23 '22
The guide is outdated to run on your PC. Use this for better results. https://rentry.org/kretard
3
u/[deleted] Aug 22 '22
Is it possible to change the Output folder Name? It isnt possible to create images when the prompt gets too long because the folder name can only have a limited length..
2
u/HelMort Aug 22 '22
So the "Weights" are online? Are the links in the guide the right one or of the leaked 4chan version?
2
u/Craftyawesome Aug 22 '22
Is there any way to choose CFG or sampling mode in the (optimized) local scripts?
2
u/[deleted] Aug 22 '22
Can you add this in the post?
2
u/codaker Aug 23 '22
Typo with 'collab'
24
u/Boozybrain Aug 22 '22 edited Aug 23 '22
You don't need Conda.
python3 setup.py install --userModify
txt2img.pyto add theldmdirectory to$PYTHONPATH. Add this at the top, wherePATH/TOis the path to where you have the code repo savedimport syssys.path.append('/PATH/TO/stable-diffusion/')python3 scripts/txt2img.py --prompt "octane render, trending on artstation. " --H 512 --W 512 --n_iter 2 --ddim_steps 175 --n_samples 112
u/cmdr2 Aug 23 '22
Hi, you can use https://github.com/cmdr2/stable-diffusion-ui to install and use Stable Diffusion locally on your computer. It installs the official docker image of SD automatically, and then gives you a simple GUI in the browser, to enter the prompt and view the generated image, using your local installation. Hope this helps!
18
u/Torque-A Aug 22 '22
I hope an easy-to-use GUI program can be developed too.
7
u/junguler Aug 22 '22
i had to use the "optimizedSD" txt2img script on GTX 1070 8 GB, it takes about 8-10 minutes to make the 10 images with the default command on that tutorial page, so far i'm loving this and find it very addicting, thanks for making this post
5
u/R2_D20 Aug 22 '22
Can someone who knows what they're doing please have a look at this and take a guess at what's wrong.
I tried the 4chan guide, and now I'm following the youtube video and I end up with the same errors. I deleted all instances of Python/Anaconda from my system and started from scratch and get same issues. I assumed it was a PATH issue but now I have no idea.
5
u/MessPuzzleheaded2724 Aug 23 '22
I think it's a good idea to clear CUDA's cache after every generated bunch, cause if you feed your graphics card more than it can chew (e.g. too large dimensions), it will throw out smth like this:
RuntimeError: CUDA out of memory. Tried to allocate 512.00 MiB (GPU 0; 8.00 GiB total capacity; 6.29 GiB already allocated; 0 bytes free; 6.87 GiB reserved in total by PyTorch)And won't run again until you restart the whole script. So, the lines
import gctorch.cuda.empty_cache()gc.collect()added in py scripts will fix the problem
2
u/anon7631 Aug 22 '22
I've tried to follow the retardsguide, but it assumes an Nvidia GPU. What do I have to change to run it on my 6800XT?
4
u/Mechalus Aug 22 '22
"ModuleNotFoundError: No module named 'omegaconf'"
tried "pip install omegaconf"
But I got an SSLError. I guess my work firewall is blocking me. Any of you smart folks know a work around?
4
u/Jp_kovas Aug 22 '22
The optimized txt2img doesn’t support custom aspect ratios? When I try anything besides 512x512 or 768x512 it gives me an tensor code error
4
u/solidwhetstone Aug 23 '22
I'm stuck and I feel so close :') Anyone know what's going on here? https://i.imgur.com/X3NGG8Y.png
4
u/cosmogonicalAuthor Aug 23 '22
I ran into this error while trying to generate a prompt:
OSError: Can't load the model for 'openai/clip-vit-large-patch14'. If you were trying to load it from '``https://huggingface.co/models``', make sure you don't have a local directory with the same name. Otherwise, make sure 'openai/clip-vit-large-patch14' is the correct path to a directory containing a file named pytorch_model.bin, tf_model.h5, model.ckpt or flax_model.msgpack.Anyone else have the issue, and a way to resolve? I don't have a directory by that name.
4
u/SleekEagle Aug 23 '22
This tutorial takes you through the entire setup on either a local machine or in Colab:
How to Run Stable Diffusion
4
u/MostlyRocketScience Aug 23 '22 edited Aug 24 '22
Some troubleshooting hints:
I had many different errors to get this to run on my PC in 512x512 resolution. Here are some of the things that might help you if you are stuck in similar ways:
conda env create -f environment.yamlIf you get the error message CUBLAS_STATUS_EXECUTION_FAILED, you might need to update cudatoolkit to the newest version:
conda install pytorch torchvision torchaudio cudatoolkit=11.6 -c pytorch -c conda-forgeor
pip3 install torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/cu116pip install -e .orconda env create -f environment.yamland thenconda activate ldmIf packages taming or clip are missing install them with pip_
pip -e git+https://github.com/CompVis/taming-transformers.git@master#egg=taming-transformerspip -e git+https://github.com/openai/CLIP.git@main#egg=clipNow I can finally run stable diffusion in 512x512 resolution on my GTX 1660Ti 6GB.
4
u/yahma Aug 24 '22 edited Aug 25 '22
FOR AMD GPU USERS:
If you have an AMD GPU and want to run Stable Diffusion locally on your GPU, you can follow these instructions:
https://www.youtube.com/watch?v=d_CgaHyA_n4
Works on any AMD GPU with ROCm Support (including the RX68XX and RX69XX series) and enough memory to run the model.
UPDATE:
CONFIRMED WORKING GPUS: Radeon RX 67XX/68XX/69XX (XT and non-XT) GPU's, as well as VEGA 56/64, Radeon VII.
POSSIBLE: (with ENV Workaround): Radeon RX 6600/6650 (XT and non XT) and RX6700S Mobile GPU.
THEORETICALLY SHOULD WORK (but unconfirmed): 8GB models of Radeon RX 470/480/570/580/590.
Note: With 8GB GPU's you may want to remove the NSFW filter and watermark to save vram, and possibly lower the samples (batch_size): --n_samples 1
4
u/Laniakea1337 Aug 26 '22
FAQ guide link point to wiki, which doesn't exist anymore. Can this please be updated and also include gui-tard. Thx
4
u/tkvishal42 Sep 03 '22
I had just wrote a windows 10 setup walkthrough, it was surprisingly quick! (it uses the latest weights checkpoint file)
read it here
7
u/TheActualDonKnotts Aug 23 '22 edited Aug 23 '22
You can also thank 4chan for the guide. People on /vg/ and /g/ have been spearheading this from the start. The v1.3 checkpoint that you all have been enjoying uncensored access to prior to the full release was leaked on /vg/.
1
u/babblefish111 Aug 24 '22
Is there a step missing in the guide? I keep getting a error message something like it can't find git command. Do you have to download git before doing anything else?
1
u/Tom_The_Moose Aug 22 '22
Any word on the possibility of using a discord bot? I have everything working on my PC, but would like to pipe prompts from discord to the script and the outputs to discord.
1
u/AFfhOLe Aug 22 '22
I'm trying to download the model from an official source (found this from the public release statement) rather than the file in step 1 of the quick and dirty guide, but I cannot find a .ckpt file to do step 3. Can someone help?
It seems like I have to jump through more hoops like installing something called diffusers, but I'm stuck on that as well.
1
u/raresaturn Aug 23 '22
Is the Discord no longer running? Been away for a few days and now I can't generate images on Discord
1
u/calculuschild Aug 24 '22
When using
n_iter, is there a way to make the output filenames include the seed? Instead of just incrementing 0001.png, 0002.png, 0003.png.... Then I can let it run for a few iterations and be able to see the seed of the one I like best? I know I can manually set a seed, but I want to somehow get the current random seed for a given image.1
u/imanimmigrant Aug 25 '22
Our of GPU ram? Running on a 2070s. I can run it s few times but then I get memory errors until I restart the machine.
1
u/Bamaraph Aug 25 '22
Hi I 'm one of the people who is running into the character limit problem. Also I have no coding experience. What should I change the "_" to? The output folder? Thanks to anyone who can help.
1
u/FoxMan91 Aug 25 '22
I think I saw other people prompts running in Google Colab notebook. Is it normal?
6
u/yurituran Aug 22 '22
Any word on if we can get this running on an M1 Max with 32GB of RAM yet? Probably not supported in this release, but Id like to at least try. Unfortunately it keeps saying im missing the cudatoolkit package and there doesn't seem to be support for running the version it needs on my M1 MacBook
3
u/EdgeDLT Aug 22 '22 edited Aug 22 '22
Perhaps someone could help me. I'm pretty sure I have everything set up correctly and with today's new weights, but I'm getting the following:
RuntimeError: CUDA out of memory. Tried to allocate 3.00 GiB (GPU 0; 12.00 GiB total capacity; 5.64 GiB already allocated; 742.96 MiB free; 8.74 GiB reserved in total by PyTorch) If reserved memory is >> allocated memory try setting max_split_size_mb to avoid fragmentation. See documentation for Memory Management and PYTORCH_CUDA_ALLOC_CONFMy prompt is just like the example:
--H 512 --W 512 --seed 27 --n_iter 2 --ddim_steps 50. GPU memory chart spikes like this.Any suggestions? Should I take the advice prompted, and what value would you suggest? I haven't tried the optimized version or lower settings, I was hoping I'd be able to push them higher rather than lower!EDIT: Replacing the txt2img script as in the r* guide resolved this. Leaving up for posterity.
3
u/Gaothaire Aug 23 '22
In case it helps others, because I had trouble changing directories in miniconda and had to do some searching, you can just use /d to make it work, no need to try and import os and os.chdir inside a python interpreter
3
u/Whitegemgames Aug 23 '22 edited Aug 24 '22
So no matter what I do I can't seem to get it to work at all for me. following the guide was fine until step 11 then I encountered endless problems. first it didn't know what python was so I installed it despite the guide not telling me to do so, then it said "ModuleNotFoundError: No module named 'torch'", so after some research I have it pip install torch, then numpy, omegaconf, pillow, tqdm, einops, torchvision, pytorch_lightning, and ldm, then it says "SyntaxError: Missing parentheses in call to 'print'. Did you mean print(self.face_rec_model_path)?" and I have no clue what to do at that point. I have tried uninstalling and reinstalling both miniconda and python on different versions and it doesn't help. Any advice would be appreciated or a link to a download I don't have to set up myself.
EDIT: I just got it working by completely removing all traces of miniconda and following a youtube guide by "tingtingin", although I still had to add "- git" under dependencies in "environment.yaml" despite him never saying to.
3
u/Mixbagx Aug 23 '22
How can I find the seed of my local run images?
3
u/wanderingsanzo Aug 24 '22 edited Aug 24 '22
So I've gotten it running with a GTX 1660 SUPER, but it can only generate a black square, even after installing CUDA drivers and adding --precision full to my prompt. Any idea how to fix? I'm using the waifu diffusion GUI version, if that helps.
3
u/vjb_reddit_scrap Aug 24 '22
I made a Step By Step Guide to run Stable Diffusion the official way on Google Colab
If anyone here struggling to get Stable Diffusion working on Google Colab or want to try the official library from HuggingFace called diffusers to generate both txt2img and img2img, I've made a guide for you.
You can even Enable NSFW if you want.
The guide is absolutely free and can be accessed here.
If the article really helped you and you wish to support me, you can buy the article for whatever price you want from here. Either way, the article you get is the same, it's completely your wish to buy it or access it for free.
3
u/Vageyser Aug 24 '22 edited Aug 26 '22
Thanks for the great guide! I've been having a lot of fun with running this locally.
I went ahead and put together a PowerShell function that makes it easier for Miniconda users to generate something at a moment's notice. I just love me some PowerShell and might consider creating something that has a GUI and will perform all the necessary installs and updates and whathaveyou.
Here is my current function, but I may add changes to it along with the python scripts to make file management easier and have it include a file with the technical details (prompt, seed, steps, scale, etc).
I even included a variable for Aspect Ratio (-ar) where you can set it to variations of 3:2 and 16:9. Anyway, enough of my yammering. Hope someone else out there finds this useful:
txt2img on Pastebin: https://pastebin.com/3wAyh3nH
img2img on Pastebin: https://pastebin.com/W6MSXQZH
updated optimized_img2img.py script: https://pastebin.com/cDgwyiym
Edits: Updated some things on txt2img and created an img2img variation. The img2image uses the optimized_img2img.py script from this repo: https://github.com/basujindal/stable-diffusion
Lines that should be reviewed and updated as needed are notated with commends. Here are the actual line numbers as of the latest update:img2img - 21, 29, 36, 43txt2img - 18, 25, 32, 39
I have removed the old code I tried to include in this comment. It was formatted terribly and ruined the overall aesthetics. I have been continually updating the script linked in pastebin as I add new features to make it better. Overall, it's still very unfinished, but as of right now I feel like it provides more value than just running the command in pythin directly since it creates a runbook that will log all of your technical details into a CSV. If anyone wants to collab on better shit I'm totally down. I may have unconventional methods, but I love the fuck out of powershell and really enjoy trying to use it for everything I can.
3
u/[deleted] Aug 25 '22
Can anyone give a rundown of scripts in script/ directory?
we know img2img and txt2img. What is knn2img and other? Are they useful?
3
u/Overpowdered_Rouge Aug 25 '22
There's a video tutorial at https://youtu.be/Kjx50IS_l4Y. It's really pretty easy though you do have to make a huggingface account.
2
u/KingdomCrown Aug 22 '22
There’s also this site you can use: https://dezgo.com/
2
u/pkcrossing89 Aug 22 '22
ModuleNotFoundError: No module named 'torch'
I have gotten to the final step of generating images, and it gives me this error. What does this mean?
2
u/StevenVincentOne Aug 22 '22
Will it run on a mac?
2
u/BernardoOne Aug 22 '22
how much time until someone puts all this together into a proper GUI?
2
u/IamGlennBeck Aug 23 '22
Is there any way to make it use more than one GPU?
2
u/Accomplished_Air95 Aug 23 '22
When trying to do step 11 of the quick and dirty guide, I got a ModuleNotFoundError. I used pip3 install to install all the missing modules. After this, I got a SyntaxError that said "Missing parentheses in call to 'print'. Did you mean print(...)?" This error referenced AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\ldm.py", line 20
2
u/Dangerous-Reward Aug 23 '22
Hey you should add the information brought up by tapucosmo on how to get better/more detailed file names with the seed info, etc. Or link to the post. Major quality of life improvement.
2
u/pavlov_the_dog Aug 23 '22 edited Aug 23 '22
Why does the guide direct users to a third party site and not the page where the official release is hosted (and also a torrent)?
Is there a guide that takes us through official channels?
2
u/DoAndroidsDreamOfArt Aug 23 '22
is there any notebook with GUI that has integrated basujindal's fork?
2
u/HurrDurrImmaBurr Aug 23 '22
I'm getting an issue following this guide https://rentry.org/kretard
When I try to run the kdiff.py script it tells me I'm missing the "pytorch_lighting module" and I can't seem to install it with the "pip install" command, someone know what to do?
I'm a total dunce on programming hence my desire for this version with a gui, but this guide seems to be missing something from my layman's perspective, every time I would try to run the script I was missing modules, just going down line by line it would say a module is missing, so I would install each one but I got to this one and I'm stonewalled. Was I supposed to install some kind of python library pack? (not sure that's even the right phrase) why is it missing all these modules and where do it get them/how do I fix it?
Thanks!
2
u/gksauer_ Aug 23 '22
Will table diffusion run on a Mac?
2
u/Naquadah_01 Aug 23 '22
thanks for posting this man, im not really into programming and this guide its helping a lot (still following the steps)
2
u/zkgkilla Aug 23 '22
struggling with step 9 "Step 9: If you have existing folders named "clip" and "taming-transformers" in /src, delete them"
i cant find the /src folder
2
u/jimmiesunrustled Aug 24 '22
So I'm trying to add the whole halving of precision thing to the base SD model since I'll be honest running a pile of python from a 4chan source makes me a bit uneasy.
So I tried adding the whole model = model.half() step to the standard txt2img.py and I'm getting a type error: "expected scalar type Half but found Float". Anyone else run into the same thing or know a solution?
2
u/A_Dragon Aug 24 '22
So you can run this on your own PC and you basically have unlimited generations?
2
u/Accomplished_Air95 Aug 24 '22
Can someone please help me with this? I finished setting up waifu diffusion as in the guide, but now I get "ImportError: cannot import name 'VectorQuantizer2' from 'taming.modules.vqvae.quantize'" when trying to run it.
2
u/bratko61 Aug 24 '22
where the fuck is the fucking /src????
2
u/TheMightyKutKu Aug 24 '22 edited Aug 24 '22
What do I do if it fails to download some of the Anaconda packages in step 10 (conda env create -f environment.yaml)? It seems it cannot extract pytorch-1.11.0 and cudatoolkit-11.3.1 even if I download it separately
2
u/miss_winky Aug 25 '22 edited Aug 25 '22
Does anyone know if any of the guides to run SD locally work for the M1 mac?*Edit, not yet available for your average Mac user (except some knowledgable people have)2
u/Any-Winter-4079 Aug 27 '22
Guide to run on M1 (Mac): https://www.reddit.com/r/StableDiffusion/comments/wx0tkn/stablediffusion_runs_on_m1_chips/
2
u/TiagoTiagoT Aug 27 '22
Is there somewhere a directory/catalogue of all the the various downloadable notebooks/scripts, and further modified SD versions?
2
u/yaosio Aug 27 '22
If you're using one of the forks that has it try out the k_euler_a or k_euler samplers. They can render an image in less than half the steps needed for other samplers. I'm doing 20 steps which takes 20 seconds on my GTX 1060. Previously I was doing 50 steps with k_lms which was 50 seconds.
You can go lower than 20 steps and still get a good image. At 16 steps every image seems to have this aura or fog on it.
2
u/carmeloanthony015 Aug 29 '22
Hi, I managed to install locally stable-diffusion flawlessly following the guide.
Then I tried to generate an image with the suggested command:
But I got the error:
So, according to troubleshooting section I changed the input command to reduce the output size to 256x256:
Now the process finished without any error but I have these two images in the output folder that don't resemble the expected output according to the guide.
My specs are:
OS: EndeavourOS (kernel 5.19.4-arch1-1 64 bit)
CPU: Intel Core i7-9700k
RAM: 32GB
GPU: NVIDIA GeForce GTX 1080:
Output of nvcc --version:
Any help?
2
u/nowfor3 Aug 30 '22
The Wiki is dead
2
u/After-Cell Aug 31 '22
I have so many questions. This single thread just isn't enough space to discuss them all. Where can we ask questions about AI image generation in general? Is there a better, more general subreddit to pool both stable diffusion and DALL-E users?
My main problem right now is that I can't have the same thing in more than one gen unless it's already famous. That is, if I generate a character and want to put that SAME GENERATED CHARACTER into a comic strip of 3 pictures, I can't. How can I do that?
Also, img2img seems OVERLOADED everywhere, including huggingFace. I can only use prompts at the moment, unless anyone knows paid access that is working right now?
2
u/derHumpink_ Sep 01 '22
is there any downside to using the HuggingFace Diffusers library? seems easier to use
2
u/Particular-End-480 Sep 03 '22
what kind / model of nvidia card? how old can it be? i know absolutely zero about the nvidia naming conventions.
2
u/Exp_iteration Sep 03 '22
I think I'm going insane, whenever I look at a *real* image of a person I no longer think they are real.
2
u/imtemplain Sep 03 '22
I've created a guide for Windows + AMD, hope it helps someone: https://www.reddit.com/r/StableDiffusion/comments/x4ec68/ive_created_a_how_to_video_on_running_stable/
2
u/gruevy Sep 08 '22
FWIW you also have to have git installed, and the bare bones instructions from the wiki don't mention that
3
u/stuntplane Aug 22 '22
No nsfw switch this sucks
1
u/dd_koh Aug 22 '22
What about when getting errors that say cuda cores are out of memory when running it on an 8gb gpu when running the optimized fork am running on a gtx1080 is this a bug?
1
u/[deleted] Aug 22 '22
Would it be possible to create weights based on a set of pictures or is that all back end stuff?
1
u/CenturionAurelius Aug 22 '22
Am I retarded or why did I only get like 4 generations with dreamstudio
1
u/Affectionate_Pin4410 Aug 23 '22
I'm running a 2060 on both my laptop and desktop. I managed to get optimizedSD to run and produce images, but my images are either a green or black square. completely blank images. Does anyone know why?
1
u/Majukun Aug 23 '22
after running it the first time is there a way to not have to reload the whole think next time ?
1
u/DarkCeldori Aug 23 '22
The official github code lacks the src folder from the guide
1
u/bytheninedivines Aug 23 '22
It won't let me download the environment. (Step 9.) I get the error:
"ClobberError: This transaction has incompatible packages due to a shared path."
1
u/DarkCeldori Aug 23 '22
I replaced the txt2img as suggested. Have 8 GB of vram. But pytorch is only reserving about 4GB and it has cuda error ran out of memory. Trying to clear cuda cache also gives error.
1
u/Big-Entrepreneur-728 Aug 23 '22
Is there a guide on what prompts can work on this? I have it up and running I just don't fully understand the limitations and custom options.
1
u/Mixbagx Aug 23 '22
Hello, I used the guide above but it is taking like forever to generate images when I used that command given in the guide. Am I doing something wrong? I used the optimized line. I am running tesla m60 with xeon e5 2690 v4.
1
u/Laniakea1337 Aug 23 '22
Thank you kind sirs, works like a charm. Time on 3080 for 5 pictures: 55 seconds
1
u/Jatobaspix Aug 23 '22
u/tresselapp save
1
u/MostlyRocketScience Aug 23 '22 edited Aug 23 '22
I've followed the "quick&dirty" guide and installed the optimizedSD repo and I get the following error:
Any idea what I could try? Should I update my CUDA version (I'm on CUDA 11.4)
When I tried the huggingface diffusers example, it just produces blobs of colors
Edit: Nevermind, works now (Took 12 minutes though for 10 images). For some reason more than 256x256 doesn't work on my 6GB GPU.
Do smaller sizes like 256x256 lead to worse images or is this just a problem with the optimized scripts?
1
u/TheTeslak Aug 23 '22
Is there really enough 4GB of video memory? Looks very economical
1
u/ThrustyMcStab Aug 23 '22
How do I run the img2img model? I have installed using the quick and dirty guide but that's only for txt2img.
1
u/Savings-Egg4621 Aug 23 '22 edited Aug 23 '22
say, is the download time for the new 1.4 model supposed to be 4gb and take 3 days? That seems extremely big ...
edit: nvm
1
u/Accomplished_Air95 Aug 23 '22
I finished the setup with the updated guide, but when I try to run it, I get a ModuleNotFoundError that says that k_diffusion is not found. "pip3 install k_diffusion" does not fix this.
1
u/Etiennera Aug 23 '22
When I try running the official img2img on my PC, I get:
Does anyone know what could be the reason?
1
u/ThrustyMcStab Aug 23 '22
Is there a way to exclude certain things from a prompt? For instance, I've been trying all day to get someone with blue eyes, and I've gotten the closest by adding 'wearing blue lenses' to the prompt, but then it gives me a lot of images with people wearing glasses as well. I'd like to exclude the term 'glasses' somehow to give me only people with no glasses on, if possible.
1
u/AwakenedRobot Aug 23 '22
is there any youtube tutorials to run it locally for double-retards like me?
1
u/shaner4042 Aug 23 '22
When I try to run the final step in Miniconda by typing "python scripts/webgui.py" I get an error code "ModuleNotFoundError: No module named 'clip'"
I accidently ran conda env create -f environment.yaml before deleting "clip" and "taming-transformers" in /src. Any way to fix this so I stop getting ModuleNotFoundError?
1
u/override367 Aug 23 '22
I've got this running but can only access it via the localhost address, how do I make it so I can access it via the machine's LAN ip from other computers?
1
u/xBLUExBLUEx Aug 24 '22
when i run a prompt a second time it generates the exact same images again, does anyone know what i’m doing wrong?
1
u/Weirdo_writer Aug 24 '22
I keep getting this error:
txt2img.py: error: unrecognized arguments: --prompt a happy dog running in a field --plms --n_samples 1
would anyone happen to know what I'm doing wrong and how to fix it? I can also try and provide more context if it's needed, thanks in advance!
1
u/Big-Entrepreneur-728 Aug 24 '22
What does --n_iter 2 part of the code actually do? I know what the rest does.
1
u/Terryfink Aug 24 '22
I'm stuck on the environment YAML file part.
I save the file from github, it saves it as a text file, and I don't know how to get from this part to replace the environment.yaml file.
1
u/OmnomoBoreos Aug 24 '22
I want to use Jupyter Widgets to build a UI cause none of the other UI repos worked for me, but I'm not sure how to add the parameters to the script. I run it with the command line code in jupyter with !python, but I want to know how to make a string and then have it instantiated into the !python line... I tried setting it as a variable with a string but it never picked it up
1
u/Accomplished_Air95 Aug 24 '22
How do I enable full precision in the waifu diffusion GUI?
1
u/Fragrant-Truck-3820 Aug 24 '22
How to delete output folders?
1
u/wonderflex Aug 24 '22
Is there a way to find out which seed was used after an image is generated? Either in the command window or after the command window has closed?
1
u/CJDAM Aug 24 '22
I edited a colab notebook to make a simple version where the parameters are configurable in the last cell.
https://colab.research.google.com/drive/1Rj1wuCHtVEDlh6GF4A_CsNciaqpvD_vM?usp=sharing
1
u/Blckreaphr Aug 24 '22 edited Aug 24 '22
I'm stuck at python can't open file 'scripts/webgui.py' :[Ernno 2] No such file or directory Edit figured it out all working now
1
u/Majukun Aug 24 '22
on img2img where do i put my input image exactly?there's no folder called input..do i have to create one?
1
u/wanderingsanzo Aug 24 '22 edited Aug 24 '22
Using GTX 1660 SUPER. Tried to generate a 512x512 image with 10 steps as a test, gave me a "CUDA out of memory" error. So I tried a 256x256 image and it went through, but I got the green result that many people have posted about. So I added --precision full to my prompt, and it gave me the error message "RuntimeError: expected scalar type Half but found Float". What the hell does that mean?
Edit: Using webgui.py again, it launches but every time I try to submit a prompt it gives me the CUDA out of memory error. Even when I ask for a single 64x64 image with 10 steps.
The specific error I'm getting is "RuntimeError: CUDA out of memory. Tried to allocate 58.00 MiB (GPU 0; 6.00 GiB total capacity; 5.16 GiB already allocated; 0 bytes free; 5.31 GiB reserved in total by PyTorch)".
1
u/MACK_JAKE_ETHAN_MART Aug 24 '22
I went through the R* guide (as of 8/24) and can't get back high resolution results.
I've read through the replies here and found information primarily regarding lower spec hardware.
I have a 3070Ti and Total Vram of 36GB and total physical memory of 31.9
I am also meeting the RuntimeError: Cuda out of memory tried to allocate
1
u/Terryfink Aug 24 '22
Anyone having an issue were it resolves a green square?
After one successful install my second install has this issue,
any help appreciated.
1
u/Nuclearfrog Aug 24 '22
Following the "https://rentry.org/SDInstallGuide" guide from the wiki.
At the step:
"mkdir -p models/ldm/stable-diffusion-v1/"
It is saying The Syntax of the command is incorrect, any help? Feel like ive done everything it asked so far.
1
u/Kukurisu Aug 24 '22 edited Aug 24 '22
Clicking on the wiki link brings up a page that just says "this page is no longer updated". Is that the correct link?
Edit: this only happens from the mobile app, the correct wiki page opens from a web browser.
1
u/WalkThePlanck Aug 24 '22
If you want to make the Gradio web interface accessible over the network (say you have a server but want to run the web interface on a HTPC), then edit the last line of the webgui.py to:
demo.launch(server_name="0.0.0.0")
Of course you'll need to modify any firewall rules you might have to allow access to TCP port 7860.
1
u/Robot_Embryo Aug 25 '22
What about Intel Mac users? Are we SOL?
1
u/chichun2002 Aug 25 '22
How do I train the model further on my own dataset ?
1
u/imanimmigrant Aug 25 '22
How long should I expect the spinning thing while creating the environment in miniconda?
I did experience some http errors and thus had to retry the create command a couple of times to get the files to download. Could that be an issue?
1
u/imanimmigrant Aug 25 '22
Is anyone else using the guide able to access the server over local network. With the name of the guide what it is I'm a little worried to ask
1
u/Chillroy Aug 25 '22
Why does this not work? It keeps printing the help menu as I've formatted something wrong.
python scripts\orig_scripts\img2img.py --prompt "an elephant" --init-img C:\Downloads\drawing.jpg --strength 0.8 --n_iter 2 --n_samples 2 --H 512--W 512My only guess is the location of the input file? Is it formatted wrong?
1
u/Chpouky Aug 25 '22 edited Aug 25 '22
Hey everyone !
I'm running a 3090 but default StableDiffusion still gives me a CUDA out of memory error at 512x512... I have to use the optimized variant. Also, I'm not able to run the optimized img2img anymore, it worked a few times but now I'm getting yet another CUDA Out of memory error.
Any way to fix this ? This is a 24Gb GPU...
EDIT: adding manually --ckpt in my .bat file apparently fixed the issue for some reason ?
But img2img still gives me the error.
1
u/Local_Pilot21 Aug 26 '22
is there a way to download the model directly to GDrive using Colab? The huggingface link requires authorization. 4GB is just too much for me. 😥
1
u/TiagoTiagoT Aug 26 '22 edited Aug 26 '22
I'm a bit confused about what the parameters do, the
--helpoutput doesn't really explain much. Does anyone know what all that mean? (I mean, a few things are obvious, likepromptandwidth, and from previous reading into other AI stuff I know theprecisionlets you go for half the number of bits, rounding the numbers a bit, to use less memory at the cost of some random deviations in the calculations; but other things don't really say much for people that don't already know what the jargon means and how the system works)1
u/Torque-A Aug 27 '22
I tried to set up the most basic prepack and got this error message:
Do I just not have enough VRAM to use SD? I swear I have like 7GB normally.
1
u/Roubbes Aug 27 '22
Does it work on Radeon yet?
1
u/showmeagoodtimejack Aug 27 '22
.
1
u/rebs92 Aug 28 '22
Here's a repo I made with two scripts to get sd with a ui running on a hosted Ubuntu instance
https://github.com/webel/Stable-diffusion-In-a-Box
1
u/Nitrozah Aug 28 '22 edited Aug 28 '22
probably been said on this subreddit many times but it's my first time here,
how do u go back to the set of images u generated on dreamstudio?
when I click on an image which I told it to generate 10 of them, I can't see anywhere to close it down to view the rest of the images
also is there a way to stop images of people going on top of another? it keeps happening about 90% of the images I do.
1
u/[deleted] Aug 28 '22
all my grids are outputting with the same name now and overwriting eachother. Any ideas on what is doing this?
1
u/Xe_05 Aug 28 '22
How do I remove what's already installed from <conda env create -f environment.yaml>? Earlier, I had an error where I was missing Git for pathname so I had to reinstall it and...It seemed like I'm missing cv2 since it was unable to import cv2 when I tested out the syntax.
1
u/scifivision Aug 29 '22
I’m using the web interface and trying to figure out how to make it accessible from the web so I can run it from the browser of my iPad etc.
I saw in this thread this:
demo.launch(server _name="0.0.0.0") that was supposedly in webui.py but I’m not finding that line at the bottom. I did find a share option in the code says “share your server on gradio.app” do I change that default to true in the code? I want to be the only one to help able you access.
In the running command I did see it says to create a public link set share=True in launch() but am still lost how to do that.
Thanks!
1
u/ziquafty Aug 29 '22
Does running the model in colab at a lower precision (float16) reduce the quality of the AI? I can run it at float32 precision but my resolution is limited to 512x512. Should I set it back to float16?
1
u/Mert_Burphy Aug 29 '22
Hey all. Running this on manjaro, everything is working well when i try to use txt2img. but when I try to use img2img, I get the following error:
Anyone have any thoughts?
1
u/cpt_flash_ Aug 29 '22
Hello, what i need to change in order to make public link, not just run it at 127.0.0.1:7860?
1
u/anphex Aug 29 '22
Is there a way to minimize that warped, almost creepy limbs and facial features the SD is often generating? I'd like my people with only 2 arms.
1
u/Performansas Aug 29 '22
I got an invite to use Stable Diffusion, but only saw the letter when a link to their discord server had expired, is there any way I could get another link?