This tutorial will provide a step-by-step guide on how to install Stable Diffusion locally on your PC. Stable Diffusion is a data version of the Dream Studio created by Stability AI. It allows users to create their own punch and gives them more control than other data text to image generators. The membership fee is $10 per 1000 standard generations, which can add up if you use multiple text to image generators. However, this tutorial will explain how to install Stable Diffusion locally and for free on your PC.
It is all legal as Stability AI actively encourages the sharing of their source code. In order to follow this tutorial, you need a Windows operating system, an NVIDIA video card with at least 4GB of V Ram and 10GB of storage space on your hard drive. We will start by downloading Python and Git for Windows, then head over to HuggingFace co, download the latest version of Stable Diffusion and copy the repository into a local folder. Finally, we will run the batch file and wait for the installation process to finish. After following these steps you will be able to use Stable Diffusion locally without having to pay any fees.
Are you looking to install Stable Diffusion on your PC? We’ve got you covered! This step-by-step guide will walk you through the process and make it easy for even the most novice user. Let’s get started!
Prerequisites
Before you can start using Stable Diffusion on your PC, you must make sure that your computer meets the prerequisites. First and foremost, you must have Python installed on your machine. It is recommended to use Python 3.10.6 as this is the version that the author of the repo has used in developing Stable Diffusion. Once you have Python installed, you should also install Git, which is a version control tool used in software development. Lastly, you will need to check if your computer has enough VRAM to run Stable Diffusion locally. If not, you can still use the one click install and run script, but you must still install Python and Git beforehand. Once you have all of these prerequisites in place, you can proceed with installing Stable Diffusion on your PC.
Download the Stable Diffusion Executable File
The next step is to download the Stable Diffusion executable file. Head to the official website and download the latest version for your specific operating system. Once you have the file, double-click it to run the installer. Follow the on-screen instructions, and you’ll soon have Stable Diffusion installed on your computer.
Install the Stable Diffusion Client
Now that you have the Stable Diffusion executable file downloaded, you can start the installation process. Open the file and follow the instructions to install the Stable Diffusion client. Make sure that you select the right version of Stable Diffusion for your Operating System. Once the installation is complete, you can start using the Stable Diffusion client on your PC.
Configure Your Network Settings
Now that you have downloaded the Stable Diffusion executable file, it’s time to configure your network settings. Firstly, you need to connect your PC to the internet. You can do this by using a wired or wireless connection depending on your preferences. Once connected, you need to install and configure firewall software such as Windows Firewall or any other third-party firewall program. This will help protect your PC from malicious attacks and unauthorized access.
After that, you need to set up a static IP address for your PC. This is important as it ensures that your PC can always be reached at the same IP address even if the network configuration changes. To do this, you need to open the Network Connections window and select the Internet Protocol Version 4 (TCP/IPv4) option. Then, enter a static IP address, subnet mask, default gateway and DNS servers in the appropriate fields.
Once you have configured your network settings, click “OK” to save the changes and then restart your computer. Your PC should now be ready to install Stable Diffusion.
Connect Your PC to the Internet
Once you have all the required software installed, you need to connect your PC to the internet. If your PC is connected to a router, make sure that it is turned on and that the Wi-Fi connection is established. If it isn’t, contact your ISP to fix the issue. Once you have an internet connection, you can proceed to the next step.
Install and Configure Firewall Software
Firewall software is essential for protecting your PC from malicious attacks, which is why it’s important to install and configure a firewall before running Stable Diffusion. There are many firewall options available, but the most popular choices are Windows Firewall, Norton Firewall, McAfee Firewall, and Kaspersky Firewall. To ensure that Stable Diffusion can communicate with its servers, you’ll need to configure your firewall to allow outgoing connections on port 8888. Additionally, you should also configure your firewall to block incoming requests on port 8888. Once you’ve configured your firewall settings, you’ll be able to proceed to the next step in the installation process.
Set Up a Static IP Address for Your PC
Once all the prerequisites have been met, you can now set up a static IP address for your PC to use with the Stable Diffusion client. To do this, open the Network and Sharing Center and click on your active network connection. From here, you can click on Properties and then select Internet Protocol Version 4 (TCP/IPv4). You can then assign a static IP address to your PC, which is necessary for the Stable Diffusion client setup. Make sure to enter the correct IP address information, as this will be used for future Stable Diffusion connections. Once you have completed this step, click OK and then close out of the Network and Sharing Center. You are now ready to begin the Stable Diffusion client setup process.
Run the Stable Diffusion Client Setup Wizard
Once you have downloaded the executable file, it’s time to run the Stable Diffusion Client Setup Wizard. This will guide you through the installation process and set up the necessary configurations for you. The wizard will prompt you to enter the IP address of your PC, the port number and any other required details. After entering the information, click on the “Finish” button to complete the installation process. Now that you have successfully installed Stable Diffusion on your PC, you can start using it to securely store and access your sensitive data.
Start Using Stable Diffusion on Your PC
Once the installation is complete, you can now start using Stable Diffusion. To do this, open the application from your desktop. You will be prompted with a welcome screen where you need to click “next” to proceed. You will then be asked to create a new account or log in to an existing one. Once you are logged in, you can start using Stable Diffusion. You can browse through your existing projects, or create a new one. The application also provides you with tutorials and sample projects that you can use to get started. Additionally, Stable Diffusion has a built-in text editor, so you can write your own code and run it on the platform. Once you are done writing your code, you can deploy the project to the cloud or locally on your PC.
Update the Stable Diffusion Client
Once you’ve successfully installed the Stable Diffusion client, it’s important to keep it up to date. Updates help ensure that the software is running correctly and can help fix any bugs or glitches that you might experience along the way. To update the Stable Diffusion client, open the application and go to the “Settings” tab. From there, click on “Check for Updates” and the client will automatically search for updates that have been released since your last installation. If an update is available, you will be prompted to download and install it. Once you have installed the latest version of Stable Diffusion, restart the application and you should be all set!
Uninstall Stable Diffusion from your PC
Uninstalling Stable Diffusion from your PC is a straightforward process. To begin, open the Start menu and search for “Add or Remove Programs.” Once you’ve located the program, select it, select the “Stable Diffusion” entry and click Uninstall. You will be asked to confirm the uninstallation process. Once you confirm, Stable Diffusion will be uninstalled from your system. If you have any difficulties during this process, you can refer to our troubleshooting guide for tips and advice.
FAQ
Q: What is Stable Diffusion?
A: Stable Diffusion is a text to image generator created by Stability AI. It works similarly to Darley and allows users to create punch from Dream Studio, which offers more control. It is currently available for a membership fee of $10 for approximately 1000 standard generations.
Q: How can I install Stable Diffusion on my PC?
A: To install Stable Diffusion on your PC, you will need Windows operating system, an Nvidia video card with at least 4GB of V-Ram, and 10GB of storage space on your hard drive. You will need to download Python and Git for Windows, sign up for a HuggingFace account and a GitHub account, download the latest version of Stable Diffusion, create a folder on your local drive, clone the repository into the folder you made, paste the weights file into the folder, and then run the batch file in the folder.
Q: Is it legal to install Stable Diffusion on my PC?
A: Yes, it is legal to install Stable Diffusion on your PC as Stability AI actively encourages sharing of their source code.
Q. How much does it cost to use Stable Diffusion?
A. At the moment, the membership is $10 for approximately 1000 standard generations.
Q. Is there a way to run Stable Diffusion locally on my PC for free?
A. Yes, you can run Stable Diffusion on your PC locally for free as long as you have a Windows operating system, an Nvidia video card with at least 4GB of V Ram and 10GB of storage space on your hard drive.
Step-by-step guide:
Step 1: Install Anaconda for managing python environments and packages:
Go to: https://www.anaconda.com/
Download the installer and follow the instructions for your operating system
Step 2: Create a huggingface token
Go to: https://huggingface.co/settings/tokens
Create a token and save it in a safe place
Step 3: Open a Anaconda Powershell (on Windows) or terminal (Linux)
Change directory to the location of your choice
Step 4: Install git through Anaconda
In the Anaconda Powershell or terminal, type:
conda install -c anaconda git -y
Step 5: Clone the github repository
In the Anaconda Powershell or terminal, type:
git clone -b local https://github.com/deforum/stable-diffusion.git
Step 6: Create Anaconda environment
In the Anaconda Powershell or terminal, type:
conda create -n dsd python=3.9 -y
Step 7: Activate the Anaconda environment
In the Anaconda Powershell or terminal, type:
conda activate dsd
Step 8: Install Pytorch
In the Anaconda Powershell or terminal, type:
conda install pytorch cudatoolkit=11.6 torchvision torchaudio -c pytorch -c conda-forge -y
Step 9: Install required packages
In the Anaconda Powershell or terminal, type:
python -m pip install -r requirements.txt
Step 10: Test your installation
In the Anaconda Powershell or terminal, type:
python Deforum_Stable_Diffusion.py
Transcript
Today I’m gonna be showing you how to install Stable Diffusion locally on your PC.
Before we go any further, I just want to say I had COVID at this point of filming this video I.
Did not know and that probably shows.
In my enthusiasm levels in this video. So forgive me, I just did not.
Want to studio to go to the waiter. For the guys who created stable diffusion. They are called stability AI. They also created the Dream Studio which is a data version at the moment which works like Darley. You log in and you can create your punch from there. You do actually have a lot more control than you do have in Darley and at the moment the membership is $10 for approximately 1000 standard generations. So while it’s not breaking the bank, if you’re like me and you have a couple of subscriptions and you’re buying credits from multiple text to image generators, it can get costly. What I’m going to show you now means that you can run Stable Diffusion, the most up to date version on your PC locally for free. So this is all legal. Stability AI actively encourage the sharing of their source code. Assuming that you have a Windows operating system and that you’ve got an end video card and you’ve got at least 4GB of V Ram, you’ll also need about 10GB of storage space on your hard drive as well. I’m going to be showing you live and I’ve done a few of these tutorials for you guys and I found this one is the simplest one to follow.
There are eight steps in total and you need to make an account with the website HuggingFace co go and sign in there and make an account and then confirm your email address and with GitHub as well. So the links are below. So hopefully you are making those accounts now as I speak and you can pause this video if you go down in the description below. I’ve named all eight steps and they have the link to go to for each step. Although you’ll find this tutorial in a written format on my website which is promptwhuse.com. So the first step is downloading Python. Click the link in the description on number one and when you get to the page, scroll down to the very bottom and you need to click on Windows installer 64 bit. This will download that file to your downloads folder and then once that’s done downloading and you need to double click the file in your downloads folder to install the wizard. Ensure that you’ve got add to path checked that’s vital, otherwise this is not going to work. Okay, onto step two. So step two is downloading Git for Windows if it is called Git Bash.
So you go to the link in the step two description below and that’s gitforwindows.org and click the lovely download button here and again that will download to your demos folder. So once that’s downloaded, you need to run the installer and double click it and it will automatically run the installer for you. Just click next. That’s absolutely fine. And once you have finished installing that, on the last page, just click Launch Git Bash. So that will launch the programme for you. Step three. This is going to the HuggingFace co link in step three. And hopefully before you pause the video and made your hugging face account and you are logged in. And when you go to the link provided, you will see download weights here, near to the top of the page. So this is the latest release of Stable Diffusion. We are on one four, but you might be in the future. So it might say one five. So just click that and download that. So now we need to navigate over to your local drive line. In this example is MYC drive. You need to right click and create new folder. Name that folder, anything you want.
Called it FD for stabledusion. Just name it absolutely anything you want. AI, artwork, whatever.
This is where we are going to.
Be copying the repo into where we’ll be running Stable Diffusion. So make it something, you know, fancy and that you will remember what it is. We are now on to step number five. So that is going to GitHub.com. So that link will take you to this page and you’ll see near to the top this big green button that says code on it. Click this button and you will see a URL. You need to copy that URL and if you’re not running Git Bash like I said previously, to launch it, just search Git Bash on your PC and you’ll find it because that’s what we install. All you need to now type is all lower case Cdspace and then the drive that you just made that folder in, which mine is C and then the name of that folder, whatever you called it, I called Mine SD and then hit Enter on the keyboard. And now you need to type in Git, git space clone, git clone and right click and paste and that will pay for the link we just got from the GitHub website. Now you need to hit Return on the keyboard once again.
That’s cloned the repository into that folder that you have just made. That’s where we’re going to now run Stable Diffusion from we return back to the drive where you saved your folder to again, mine was C drive and what’s called SD and you will see a folder in there now. So we need to open that up and navigate down to models and then Stable Hyphen Diffusion should be in there. Now we downloaded that SDV one Hyphen four CKPT file and that should be chilling out in your downloads folder now. So go back to your download folder.
You need to right click and then cut and paste into that Stable Diffusion folder.
We are pretty much done. All we need to do now is come up to levels in that folder and you will see the batch file. Weboo user double left click to run that batch file. This will now install stereo diffusion on your PC.
Installing all the assets will take a few hours. It’s better to leave it running overnight. If you think it’s crashed or paused, just hit spacebar on the keyboard and that should get it running again. Do not click anywhere in the box because this will pause and freeze your installation. Once it’s finished, it will let you know it’s done, and you just copy the IP address that you’re given and paste it into your Internet browser. And there you go. That stable diffusion on your machine locally.
1 Comment
I blog quite often and I truly thank you for your content.This great article has truly peaked my interest. I am going to takea note of your blog and keep checking for new detailsabout once a week. I opted in for your RSS feed too.