Sunday 27 August 2023

Automatic 1111 -- Stable Diffusion

Automatic 1111-Stable Diffusion allows me to upload a figure drawing on my own computer, and generate an AI image from that image -- and it works quickly, way faster than Midjourney:

Generating AI Art from an image
on a local computer --


We have been using Automatic 1111 at Quelab after Grant lent his powerful computer (with a powerful RTX video card) to the hackerspace on August 2nd.  Within the week Adam had installed Stable Diffusion (Automatic 1111) and various models from Civitai to work from.  He also set up remote access so that I could generate AI Art from my home, using the Quelab computer.  Amazing!

AI PRINT


Just for fun, I used AI to animate one of the Automatic 1111 art generations, using PIKA LABS in Discord:



CIVITAI MODELS

In order to generate images with Automatic 1111-Stable Diffusion one needs to use AI "models."  Adam downloaded the most popular models from CIVITAI -- and "placed the model inside the "models/Stable-diffusion" directory of your AUTOMATIC1111 Web UI instance."

I also uploaded a "model" based on my drawings that was created online in Open Art (using PhotoBooth):

model_20221213233657.ckpt  (2 GB)


DEFORUM

Within Automatic 1111 is a tab for DEFORUM, which is a program for making AI video.  

I uploaded four of my drawings to Deforum and generated the AI art video below:


NOTE:  I generated the Deforum video from the model based on my drawings



We found out how to use "image prompts" in Deforum, by opening the "Guided Images" carrot, and pasting in the URLs of the key images we wanted to insert:

Open the "Guided Images" tab by checking the carrot.  Then replace the images, by pasting the URLs of your images into the box below:

 August 14, 2023

Open the "Guided Images" box 
by checking the carrot,
and paste your image URLs into the code


ALSO, change the text prompts in the code box below to your liking (example: "figure drawing of a woman):

Using "Image Prompts"
in Deforum



Other DEFORUM videos



Another example: Adam's Deforum AI video:


LORA Models

Automatic 1111 even allows you to train your own "models," which makes it even more powerful.

However LoRAs (Low Rank Adaption for fast text-to-image diffusion fine tuning) can train with 30 images, rather than a data base of infinite images.


 USING LORAs

To use a LORA in Automatic 1111 is a little different from just choosing a regular model:

    • To install LoRA models in AUTOMATIC1111 webui, put the model files in the following folder:
stable-diffusion-webui/models/Lora
    • To use a LoRA model, put the following phrase in the prompt.<lora:filename:multiplier>
    • filename is the file name of the LoRA model, excluding the extension (.pt, .bin, etc).
      • multiplier is the weight applied to the LoRA model. The default is 1. Setting it to 0 disables the model.
    • How can you be sure the filename is correct? Instead of writing this phrase, you should click on the model button.





No comments:

Post a Comment

Note: only a member of this blog may post a comment.