avatarJim Clyde Monge

Summary

This article explains how to set up a Stable Diffusion environment and run it on the CPU without a GPU.

Abstract

In recent times, artificial intelligence (AI) has been increasingly used to generate detailed and photorealistic images. However, running these tools locally typically requires a powerful GPU, which can be expensive and hard to come by. Fortunately, a method has been developed to generate images using AI without a GPU. This article provides a step-by-step guide on setting up a Stable Diffusion environment and running it on the CPU. It includes system requirements, how to set up the one-click Stable Diffusion Web UI, and a warning about the generation process being slow. The article concludes by expressing optimism about the future of AI tools becoming more accessible to everyone.

Opinions

  • Using AI to generate images without a GPU is a significant development.
  • Setting up a Stable Diffusion environment and running it on the CPU is feasible.
  • Running AI tools on the CPU is slower than on a GPU, but it doesn't affect the final result's quality.
  • The hardware requirements for running AI models are becoming less demanding.
  • The author is optimistic about the future of AI tools becoming more accessible to everyone.
  • The author recommends trying out an AI service that provides the same performance as ChatGPT Plus but is more cost-effective.
  • The technology is improving rapidly, leading to more powerful AI tools becoming available to everyone.

How To Run Stable Diffusion Locally Without GPU

Image by Jim Clyde Monge

In the past few months, more and more people have been using artificial intelligence (AI) to generate incredibly detailed and photorealistic images.

However, running these tools locally typically requires a powerful graphics processing unit (GPU), which can be expensive and difficult to come by.

Fortunately, there is now a way to generate images using AI without a GPU. With the advancement of technology, the hardware requirements to run these powerful AI models are becoming less demanding, enabling people to run the tool without a GPU.

In this article, I’m going to explain how you can set up a Stable Diffusion environment and run it on the CPU.

System Requirements

  1. Windows 10/11 (Linux is also supported but this tutorial will focus on the Windows environment)
  2. 25 GB of local disk space.

If there’s no problem with the above requirements, let’s proceed with the tool setup.

Setup the One-Click Stable Diffusion Web UI

Download this zip installer for Windows.

Extract the folder on your local disk, preferably under the C: root directory.

Next, double-click the “Start Stable Diffusion UI.bat” file. It will download all the dependency files for you. The total file size is around 10 GB, so go grab a coffee or snack while you wait for the download to finish.

Image by Jim Clyde Monge

Once the setup is finished, a browser UI should be launched automatically.

Image by Jim Clyde Monge

Now go to the System Settings tab and toggle the “Use CPU” button.

Image by Jim Clyde Monge

That’s pretty much it. You can now start generating images.

Warning: The generation is incredibly slow.

On a CPU with the following specs, it took about 10 minutes to make a 512x512 JPEG image:

Processor Intel(R) Core(TM) i7–9850H 
CPU @ 2.60GHz, 2592 Mhz, 6 Core(s), 12 Logical Processor(s)

Here’s the image result.

prompt: An astronaut riding a horse in space
Image by Jim Clyde Monge

If you switch from GPU to CPU, it won't change the quality of the final result; only the render speed is affected.

Despite these limitations, the ability to run a stable diffusion locally without GPU is a great development for developers and users alike. It allows individuals to access powerful AI tools without having to invest in expensive hardware.

The technology is improving very quickly, so it is likely that the hardware requirements to run these AI models will become even less demanding in the future. This could lead to even more powerful AI tools being available to everyone, regardless of their hardware capabilities.

Technology
Artificial Intelligence
Future
How To
Stable Diffusion
Recommended from ReadMedium