1

I want to setup Stable Diffusion (server?) to emulate some scenes in some works of fiction I've worked on over the years (e.g. "self-made" concept art). However even as a developer I'm completely lost on the provided instructions as I'm not familiar with any of the prerequisites involved.

I've obviously have read the readme file and installed Conda however the instructions are extremely lacking as they clearly presume you already know what you're doing. Then after installation I ran the very first command:

(base) PS C:\Users[user]> conda env create -f environment.yaml

I received the following error:

EnvironmentFileNotFound: 'C:\Users[user]\environment.yaml' file not found

How do I properly setup Conda, Python and Stable Diffusion?

I'm interested in getting through the whole process, not just the first error.

desertnaut
  • 57,590
  • 26
  • 140
  • 166
John
  • 1
  • 13
  • 98
  • 177
  • you can't just jump into the deep end of machine-learning – Nicholas Hansen-Feruch Oct 29 '22 at 03:02
  • Have you cloned that repository? The environment.yaml file is in that repo. Clone it to your computer, cd into that folder, *then* run the `conda env create -f environment.yaml` command – C.Nivs Oct 29 '22 at 04:36
  • @NicholasHansen-Feruch how is that helpful to OP? – C.Nivs Oct 29 '22 at 04:36
  • Also, for what it's worth, any time they say `pip install `, do `python -m pip install `. It will most likely save you from "I have pip installed X module but it says module not found" – C.Nivs Oct 29 '22 at 04:43
  • @C.Nivs What do you mean clone it to my computer? The only cloning I do is with hard drives and partitions. I'm running Windows 10 x64. – John Oct 29 '22 at 06:51
  • Ah, ok, then you might want to look into [git](https://git-scm.com/download/win). This is a repository that is expected to be on your machine for the commands in the README to work. `git` will download the repository for you – C.Nivs Oct 29 '22 at 15:13
  • @C.Nivs So...what is the `git` part then? Could you please post instructions in an answer? – John Oct 30 '22 at 07:27
  • If you're just interested in the result, and don't have any familiarity with the code, it'd be easier to use one of the packages or guides that does most of the setup for you, eg: https://rentry.org/nai-speedrun – CertainPerformance Nov 21 '22 at 03:49

2 Answers2

3

The reason your commands aren't working is that you need to git clone the repository first:

git clone https://github.com/CompVis/stable-diffusion.git

Which will drop a stable-diffusion folder where you ran the command. Once you cd into that directory, you should see an environment.yaml file that you can use for your conda commands:

cd stable-diffusion

conda env create -f ./environment.yaml

If you don't have git installed, you'll want to use a suitable installer from here.

C.Nivs
  • 12,353
  • 2
  • 19
  • 44
  • Thank you - that got me a bit further but holy hell it's a nightmare of tangled dependencies and I hit yet another error that I just couldn't get past. I've got way better things to do than waste time on stuff that clearly is a nightmare of a mess and not organized in the least. They need a download, install and run a binary option because only hardcore Python users can dig through all of that. Thank you for trying any way. – John Nov 26 '22 at 08:11
0

Yes, there are those "easy" options too, such as .exe and .dmg installer files for Windows and Mac's respectively.

There are also some simpler than what you found daunting, but less limited than the above pre-defined, self-contained options, such as via: https://github.com/cmdr2/stable-diffusion-ui

Every option/approach has its trade-offs.

The underlying issue you are contending with is that you are jumping in at the point of 400% - 1,000% yearly AI growth rates and all the rapid changes in evolution and options that this implies, and the desire to bypass the challenge on jumping onto the rapid technology, code and related options that this is. Many of the people, groups and companies powering this amazing revolution and growth rates and sharing this with others also have time constraints, and therefor are fine providing standard modes of setup and access via industry-standard tools and methods like GitHub, Conda, Brew and other such tools. However, a certain percentage of people will be frustrated by this. For them, there are other simplified, less leading-edge access options.

While there are simple installs that are self-contained and relatively easy, they by their nature provide a smaller slice of any given area of AI, which is simplifying for the knowledge/time-constrained individual at the expense of limiting access to many the latest installable or other options.

You can also just use an online version of it where someone has done the more difficult installation and configuration work for you. From Mid Journey and Google Colab options to things you can simply find by searching for online stable diffusion, such as: https://stablediffusionweb.com