Great overview of installing and running stable diffusion locally, but judging by the issues in the comments I think it needs to cover what to do if a newer version of Python is already installed. I am an absolute beginner :) but the way I got around the PyTorch version issue was to install Python 3.10.6 to a different directory to my current python installation, selecting the Add to Path checkbox during installation. Then, before running webui-user.bat, I had to edit my user environment variables by selecting the Python 3.10.6 path and clicking the Move Up button so that it appeared before my Python 3.12 path in the list. Then stable diffusion could be installed OK, although I had to update my NVidia drivers before it would generate images. I hope this helps somebody!
I searched the internet for 45 minutes and figured out the issue. Then checked the comments and saw this, which would have saved me the 45 minutes. Ha. I ended up uninstalling 3.12 and installing 3.10.6, which worked for me. Version 3.12 gets the Torch error.
@neilie6593 -- I have a feeling that this addresses the problem that I am having after doing the same (installing the latest build of Python, but the command prompt window saying that Python could not be found). Alas, I don't understand most of what you said after describing your problem. I downloaded 3.10.6, but I don't know where I should install it, nor how one edits "user environment variables", etc. Any chance the directions could be broken-down a bit for we mere mortals?😅 Thanks!
Great video thank you but I'm having trouble downloading stable diffusion there is no webUI.bat file. There is one called webui-user and it's a windows batch file. When I try to open it windows 11 says defender smart screen prevented an unrecognised app from starting. Running this app might put your PC at risk. The only box I can take on is don't run or the close the window x button. I've installed python. any ideas .thanks
Hi! I got a very similar screen. It wouldn't show the "run anyway" button unless I clicked on the little v arrow to get more information. Once i clicked and it revealed a few lines of information about the name of the program, the button appeared. I guess Windows is trying to make you think harder before you run stuff?
Thanks for your excellent video. I was able to get everything installed despite the python version and torch snafu's how after entering a very simple prompt all I ever get is "in queue" and nothing happens after an hour or so. So after an install that took about two hours, I am simply giving up and going back to some free web based AI generators. Thanks again.
I would love to see how you can input images to help train it to a certain direction, for example as a game developer i'd love to input my previous made textures to get similar results, as my artistic style is quite unique
confusing. Web UI gives error that it was designed using python 3.10. So I deleted python 3.12.1 and installed 3.10 But now when running Web UI it says it cant find folder of python 3.12.1...which makes sense as I deleted it and installed 3.10 (which is in the proper Programs folder) but apparently this web UI is not compatible with python 3.10? argh. any ideas? thanks
@@chrtsng3722 there are quite a few other videos with slightly different instructions on installing all this so I will try those. If I'm successful I'll let you know.
@@SurfacedStudio i did that. Completely removed 3.12.1 and installed 3.10. I double checked that a 3.10 folder had been created in the Programs folder… but command prompt web ui says cant install as python 3.12.1. not found. Thats why I wondered if earlier version of web ui is needed instead but the list of past versions doesnt make it easy to see which is the correct to use. thanks. To confusing for me.
I think I found a fix. I had the same thing happen to me. I whet to C:\Users\(YOUR NAME)\AppData\Local\Programs\Python. then i changed the folder name from Python310 to Python312. I think it is looking for the new vision of Python even though it is incompatible so you have to trick it. If u cant tell i don't know much about Python lol. @@pixelkat1819
When I try to open webui-user.bat file I get the message saying "No module named pip" and "Launch unsuccessful. Exiting." Does anybody face the same issue? It happens when I use Python 3.11.5 as well as 3.12.3
I have tried several times and keep getting this message: ERROR: Could not find a version that satisfies the requirement torch==2.1.2 (from versions: 2.2.0, 2.2.0+cu121, 2.2.1, 2.2.1+cu121, 2.2.2, 2.2.2+cu121, 2.3.0, 2.3.0+cu121) ERROR: No matching distribution found for torch==2.1.2
@@3sguitar It's telling me "This program is tested with 3.10.6 Python, but you have 3.12.3." I'm going to try uninstalling python and re-downloading the 3.10.6 version
Gotta remove the new version of Python, and pick a 3.10 version. Also remember to delete the venv folder in your stable diffusion ui folder, or else it will continue looking for your Python in a 3.12 folder (or whatever version you previously downloaded). When you double click the bat file to start again, it'll create a new venv folder with the new 3.10 location.
You might not have the right version of Python installed. Check with the SD version you downloaded what version of python you need. Then uninstall any you might already have and only install that specific one - that seems to resolve it for most people
hey, thanks for this amazing tutorial. I've been trying to follow the steps, but when I press run for webui-user.bat I met two errors: [1]installing torch and torch vision - where torch couldn't be fetched. [2] an error checking the latest version of pip. wondering if you have any experience on those two issues? thank you
Hm can’t say I have unfortunately. The failing to fetch sounds like a networking issue and the pip versioning seems like some local tools not working. What OS are you on?
I had the same issue. I just had to delete python 3.12 and install version 3.11.5 instead. Then I also had to install Git. But after that the script ran through. It works for me now. I was just able to generate my first smiling cat 😸
If you need to have multiple versions of python running, you need to run the pip command like: `python -m pip --python \python.exe install pytorch`. Then in webui-user.bat, set the python variable to point to your python.exe
Hi There! Thanks for the great and easy to follow video. I have a problem though and I hope you can help, when I run the webui-user (mine does not say .bat) it does say windows batch file after the date and time So when run it I am getting "could not find a version that satisfies the requirements for torch==2.0.1 ( from versions: 2.2.0, 2.2.0+cu118, 2.2.1, 2.2.1+cu118) ERROR: No matching distribution found for torch==2.0.1 Then some white text and ERROR code 1 press any key to continue, I press, it closes down... what have done wrong is my computer missing something to be able to run it? I'm not that technical, I only learn what I have to to do the things I want to do and I would love to try stable diffusion.
I think knowing how to use these tools to get great output is the real magic. But I'm trying to make up for my lack of artist's skills, rather than using it for an ideas system. Very interested in any follow ups you do
I keep getting the error: "File "C:\Users yan1\OneDrive\Documents\stableDiffusion\stable-diffusion-webui-master\stable-diffusion-webui-master\launch.py", line 48, in main() File "C:\Users yan1\OneDrive\Documents\stableDiffusion\stable-diffusion-webui-master\stable-diffusion-webui-master\launch.py", line 39, in main prepare_environment() File "C:\Users yan1\OneDrive\Documents\stableDiffusion\stable-diffusion-webui-master\stable-diffusion-webui-master\modules\launch_utils.py", line 386, in prepare_environment raise RuntimeError( RuntimeError: Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variable to disable this check Press any key to continue . . ." whenever i run the webui-user batch file, any ideas why?
I guess I'm not an absolute beginner! LOL I'm trying to come up with the more appropriate adjectives but somehow my choices are probably not considered acceptable language on RU-vid.
@@SurfacedStudio this is the most recent reply i could find, mine seems to download fine but becomes stuck once its 100% downloaded, just ssaying theyres 2.5gb/2.5gb ? eta: 0:00:00
Interesting! However, with all of the issues I've read below, I think I'll stick with traditional art, like a certain Jack 'King' Kirby. All he needed was a pencil, paper and his cigar. 'nuff said!
Can you be more specific? “My car doesn’t start” is hard to diagnose via internet. Where is the error, what does it look like, what have you tried, what happened when you tried those solutions, what are you trying next?
venv "C:\Users\Kedem Dray\Desktop\New Stable Diffusion\stable-diffusion-webui-master\venv\Scripts\Python.exe" Python 3.10.6 (tags/v3.10.6:9c7b4bd, Aug 1 2022, 21:53:49) [MSC v.1932 64 bit (AMD64)] Version: 1.9.3 Commit hash: Traceback (most recent call last): File "C:\Users\Kedem Dray\Desktop\New Stable Diffusion\stable-diffusion-webui-master\launch.py", line 48, in main() File "C:\Users\Kedem Dray\Desktop\New Stable Diffusion\stable-diffusion-webui-master\launch.py", line 39, in main prepare_environment() File "C:\Users\Kedem Dray\Desktop\New Stable Diffusion\stable-diffusion-webui-master\modules\launch_utils.py", line 386, in prepare_environment raise RuntimeError( RuntimeError: Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variable to disable this check Press any key to continue . . .
@@SurfacedStudio Lol I can imagine! With SD specifically it seems like every single process has a billion steps to get through but you're right, I guess that's everything
My generations all come out looking terrible. Just tons of weird stuff. Additional hands, legs, extra heads, weird psychedelic glitchiness all around, I can't get it working right at all to produce anything halfway useful.
@@SurfacedStudio Thanks, I did a little research into connecting an external GPU rig into my Mac Mini but feel it will just be bottlenecking the GPU. So I'm going to upgrade my PC build instead, I've been spoiled by the glamorous life of low spec Macs. 😂
Python not found.. press key to exit. So before you waste your time like I did, this doesn't seem to work anymore, the right version of python doesn't seem supported anymore so I can't download it, so all this is for nothing thanks.
You do realize, it's not really ai like in the movies, right ? It's another computer program, like all the other programs that your using, where programmers sat down and hard coded like 20% to 50%, and the rest of the code was completed by libraries of code the program has in its database, developed from humans in the past. Programmers have been doing this for decades, although it's not quite as easy for the coder as these programs are making it for general user... still, it's JUST a program that interprets a user's simplified code words and then references actions it should take based on those words. These "ai" programs aren't exactly intelligent and are more like really decent at decoding adjectives and nouns, and then referencing a database of what to do with those words. So, really, your "moral" opposition to this, is really towards computers in total, and you should go back to the 1940's before there were computers.
@tyrzxv lol lmao imagine being such a dork and defending this shit, yes I know it's not actual Ai like "the movies" I know it was programmed by unethical losers who don't have an imagination and train their loser program on other people's work to generate this shit. Go touch grass.
Hey man, why is this unethical? I'm honestly curious, I'm just starting to search this. It's the first time I'm seeing someone say it's unethical. Can you recommend a video or channel about this?
It's just another program, like all other programs on your computer, that decodes words you give it, into actions. There is no real intelligence in these programs, and people are so attached to the "ai" buzzword without realizing that it's still just a program with a large database. In a way, it's a bit hypocritical to say it's unethical, if your using a computer at all, since computers were unethical ways of creating art back in the day. Plus every program you use, was written by a coder in a more archaic form of this same technique that people are now calling "ai".
I'm not at all impressed by the results shown in the video. Is this worth the hustle? I've used several paid AI image generators that produce truly amazing results and take your feedback to improve. Does Stable Diffusion take any form of feedback from the user to regenerate an image? Would I be able to train a model?
Smart pick using Stable Diffusion and not the commercial/paid tools! 👏🏽👏🏽 Pay no attention to the unsubbers. I'm in the vfx field and aeeing content from a vfx artist trying to integrate ai into their workflow is good to see... because its exactly what the big studios are already doing. So the same short-sighted naysayers here are the same types who were yelling back in the day to shun the Photoshop artists...digital cameras and digital cinematographera...and any artist really who used the computer. Heard these types of complaints thru the years so many times...and they fade away quick because they get left behind. "Adapt or die" in our field has always been true, and still is. Ai isn't going to take your artist job....an artist that knows how to properly use Ai is going to take your artist job. It's an uncomfortable fact, but it's happening.
Sorry but you are wrong. You can’t compare cameras, photoshop with ai. Does cameras used every painting to make photos? Was photoshop built on others people artwork? „Adapt or die“ yes artists are adapting thats why ai techfirms getting sued. And btw your „artist using ai“ will be gone very fast too. If ceos can easy use ai they don’t need an „ai artist“
The thing is though, photoshop and cameras still need talent and need to be used in combination with other skills like lighting, composition, framing, technique, colors, etc. All ai needs is a sentence, its a way different level of effort and very much not the same thing
I successfully entered the 8:50 webpage ui, but when importing v1-5-pruned-emaonly, I got an error Expecting value: line 1 column 1 (char 0). Does anyone know what I should do?
Thanx for this tutorial. On Linux it installs like a charm, there is a script that makes it easy, even with a higher version of python it works perfect 👌
I don’t think that’s a thing. But I might be wrong, there seems to be a market for anything these days. It’s pretty easy to install yourself so not sure if people would pay for that
I follow the steps but looks like it's not working well with the last version of Python 3.12.3 because can't install it: Couldn't launch python exit code: 9009 stderr: Python was not found; run without arguments to install from the Microsoft Store, or disable this shortcut from Settings > Manage App Execution Aliases. Launch unsuccessful. Exiting. Press any key to continue . . .
AI isn’t ‘smart’. It’s good at identifying and applying patterns very very efficiently. It does not ‘understand’ how many fingers humans have because it doesn’t understand what humans are ;)
The way you explained is perfect for a layman like me. Before coming to your video, I saw many, but none could make a layman understand sd so easily as you did. U deserve a line and su subscribe. Looking forward for more AI stuffs in simple language.
well took me a few hrs of troubleshooting but I finally got it work. the only downside is I am having to use my CPU instead of my GPU and renders take forever. Anyone know how to get it to work with AMD GPUs? I have A RX 6600.
Hello brother. I'm new to AI. I'm curious about why some people are claiming this to be unethical. Is it Stable Diffusion or AI in general? I'm new to this, can you give some insight? I want to know if I'm missing something before getting involved.
Omg I'm so excited, a right-wing AI that's not censored and controlled by the disgusting left wing monsters, and it's totally decentralized, I love this, I'm gonna make so much money creating funny AI images haha. These guys that are developing these open-source tools are the real heroes.
Why do all of you think everyone is living under a rock because they don't know ai? Maybe people actually have skill and prefer to draw by hand or actually do photography, being able to put words in a prompt literally requires no talent.
There's a difference between 'not knowing AI' and 'not having heard of AI'. I think if you fall into the latter category and you've somehow come to this video then some news might have passed you by. Also, do note that I deliberately never call it AI 'art' anywhere in this video. It generates AI images. Whether it's 'art' is a separate discussion
I try to installed again but looks like it's not working anymore with the recently version of Python: Creating venv in directory C:\Users\Kedem Dray\Desktop\New Stable Diffusion\stable-diffusion-webui-master\venv using python "C:\Users\Kedem Dray\AppData\Local\Programs\Python\Python312\python.exe" venv "C:\Users\Kedem Dray\Desktop\New Stable Diffusion\stable-diffusion-webui-master\venv\Scripts\Python.exe" ============================================================================================================================= INCOMPATIBLE PYTHON VERSION This program is tested with 3.10.6 Python, but you have 3.12.3. If you encounter an error with "RuntimeError: Couldn't install torch." message, or any other error regarding unsuccessful package (library) installation, please downgrade (or upgrade) to the latest version of 3.10 Python and delete current Python and "venv" folder in WebUI's directory. You can download 3.10 Python from here: www.python.org/downloads/release/python-3106/ Alternatively, use a binary release of WebUI: github.com/AUTOMATIC1111/stable-diffusion-webui/releases/tag/v1.0.0-pre Use --skip-python-version-check to suppress this warning. ============================================================================================================================= Python 3.12.3 (tags/v3.12.3:f6650f9, Apr 9 2024, 14:05:25) [MSC v.1938 64 bit (AMD64)] Version: 1.9.3 Commit hash: Installing torch and torchvision Looking in indexes: pypi.org/simple, download.pytorch.org/whl/cu121 ERROR: Could not find a version that satisfies the requirement torch==2.1.2 (from versions: 2.2.0, 2.2.0+cu121, 2.2.1, 2.2.1+cu121, 2.2.2, 2.2.2+cu121, 2.3.0, 2.3.0+cu121) ERROR: No matching distribution found for torch==2.1.2 Traceback (most recent call last): File "C:\Users\Kedem Dray\Desktop\New Stable Diffusion\stable-diffusion-webui-master\launch.py", line 48, in main() File "C:\Users\Kedem Dray\Desktop\New Stable Diffusion\stable-diffusion-webui-master\launch.py", line 39, in main prepare_environment() File "C:\Users\Kedem Dray\Desktop\New Stable Diffusion\stable-diffusion-webui-master\modules\launch_utils.py", line 380, in prepare_environment run(f'"{python}" -m {torch_command}', "Installing torch and torchvision", "Couldn't install torch", live=True) File "C:\Users\Kedem Dray\Desktop\New Stable Diffusion\stable-diffusion-webui-master\modules\launch_utils.py", line 115, in run raise RuntimeError(" ".join(error_bits)) RuntimeError: Couldn't install torch. Command: "C:\Users\Kedem Dray\Desktop\New Stable Diffusion\stable-diffusion-webui-master\venv\Scripts\python.exe" -m pip install torch==2.1.2 torchvision==0.16.2 --extra-index-url download.pytorch.org/whl/cu121 Error code: 1 Press any key to continue . . .
Now said that I don't have Python 3.10.6 installed: Couldn't launch python exit code: 9009 stderr: Python was not found; run without arguments to install from the Microsoft Store, or disable this shortcut from Settings > Manage App Execution Aliases. Launch unsuccessful. Exiting. Press any key to continue . . .