This post is a guide to installing ComfyUI and Stable Diffusion XL (SDXL) within an Anaconda environment on an Ubuntu distro. It covers the environment setup, using git to clone the ComfyUI repo, downloading the SDXL checkpoints, and combining a few other tools. This guide also includes references to other, popular workflows.
Attributions:
https://aituts.com/comfyui/↗.
An Introduction.
Prompting AI to generate images was a Big Deal in 2023. This post shows how I put together a few tools so I can make AI-generated images, too.
The purpose of this post is to install ComfyUI and SDXL.
The Big Picture.
The practical reason for installing ComfyUI is to generate images for my posts and projects. In the future, I also want to write a post about combining the ComfyUI server with an image editor. (Foreshadowing much?)
Python projects can run in virtual environments. These isolated spaces are used to manage project dependencies. Different versions of the same package can run in different environments while avoiding version conflicts.
venv is a built-in Python 3.3+ module that runs virtual environments. Anaconda is a Python and R distribution for scientific computing that includes the conda package manager. Miniconda is a small, free, bootstrap version of Anaconda that also includes the conda package manager, Python, and other packages that are required or useful (like pip and zlib).
To save some time and bandwidth, I usually copy-paste local copies of the custom_nodes and models directories. When I make changes to ComfyUI, I also update these directories. Below are the processes I used to build these directories.
Cloning the ComfyUI Manager.
NOTE: This is part of my local copy-paste custom_nodes directory.
Below is a small list of tools that may (or may not) come in handy.
VAEs.
NOTE: This is part of my local copy-paste models directory.
VAE (Variational Auto Encoder) is an AI neural network architecture. During training, encoding distributions are regularised so its latent space allows a model to generate new data.
I download and place the VAE in the ComfyUI/models/vae directory.
This post provided a comprehensive guide to installing ComfyUI, the ComfyUI Manager, and SDXL within an Anaconda environment running on an Ubuntu distro. It started with setting up a conda environment, moved on to installing the necessary components, and eventually described how to run the ComfyUI server and view the UI in a browser. This guide also provided links to other tools and workflows. By following these instructions, I was able to set up, and run, ComfyUI and SDXL on my PC.
In Conclusion.
I was looking to install ComfyUI and SDXL within an Anaconda environment on my Ubuntu system. As a result of my investigations, I ended up with this guide.
In this post, I went through the environment setup, used git to clone the ComfyUI repo, downloaded the SDXL checkpoints, and combined ComfyUI with a few other tools and workflows.
Why would I want to install ComfyUI? Well, it’s an amazing tool that I can use to generate images for my posts and projects.
I used a Debian-based distro called Ubuntu, as well as Anaconda, to get started. From there, I went through using Anaconda to setup an environment, cloning the ComfyUI repo, installing the ComfyUI requirements, and cloning the ComfyUI Manager. To save time and bandwidth, I copy-pasted a local copy of the 50GB+ models directory into the ComfyUI directory. I also included links to download the SDXL checkpoints, a list of tools, and a few workflow references.
By the end of this guide, I was able to efficiently set up and run ComfyUI and SDXL on my PC. This comprehensive guide makes the setup process a lot easier for me. (As a development workstation, I’m constantly destabilising this system. Yes, I’m always cloning (and using) recovery images, but these guides are also part of my Upgrade Plan for when the next LTS distro is released.)
Have you dived into the world of ComfyUI and SDXL? Let me know in the comments below if you’ve used ComfyUI or SDXL before, and what your experience was like.