Background
Stable Diffusion is a text-to-image diffusion model that can create an AI image from a given prompt. I wanted to test it on my M1 Macbook.
Setup
Setup was fairly simple. I followed the instructions on Lincoln Stein’s fork of Stable Diffusion for M1 Macs, and despite all the disclaimers, the process worked like a charm. There is rapid development across Stable Diffusion and pytorch nightly, so my experience could be attributed to lucky timing, YMMV.
I do experience some of the bugs already reported as issues — occasionally my generated output is an black square.
Getting any output image was slow since I couldn’t take advantage of CUDA cores, and was running everything off CPU. I am lucky enough to have a friend with a beefy Nvidia GPU though — I’ve attached some of the interesting images generated at the end.
Images
”ocean”. First photo was created with only one pass.
![ocean1](/2022-09-03/00000.png)
![ocean2](/2022-09-03/00001.png)
![ocean3](/2022-09-03/00002.png)
”game of thrones anime"
![game-of-throne](/2022-09-03/00021.png)
"thanos eating popcorn"
![thanos-popcorn](/2022-09-03/00032.png)
"dog king"
![dog-king](/2022-09-03/00029.png)
"cat in armor high def”
![cat-knight](/2022-09-03/00025.png)
I also tried out the img2img
command, turning the last photo into a “drawing”.
![cat-knight-drawing](/2022-09-03/00003.png)
And, a profile photo for myself.
![me](/2022-09-03/grid-0069.png)
More Images
These photos were generated with my friend’s desktop — he has an AMD 5950x, RTX 3080 FE. Super fast — much easier to iterate on good prompts and search for better seeds.
![cityscape](/2022-09-03/0004.png)
The following is the original generated from txt2img
, the rest are
alternatives/improvements using img2img
.
![cyborg](/2022-09-03/grid-0012.png)
![cyborg1](/2022-09-03/0012.png)
![cyborg2](/2022-09-03/grid-0004.png)
![nicolas_cage_party](/img/nicolas_cage_party.gif)