Stable Diffusion tutorial, realize clay filter (special effect)

Hello everyone, I have introduced several articles about Stable diffusion before, including its installation, introduction to Wensheng pictures, and model sorting. Today I will introduce you to the actual combat of Stable diffusion, which is also the most popular clay filter (special effect).

1. Large model selection

As mentioned in the previous article on model sorting, the large model (base mold) of SD is very important and determines the style of the output.

Generally, the images we use to generate clay filters are real people, so here we use a real model: LEOSAM's HelloWorld XL

Stable Diffusion tutorial, realize clay filter (special effect)

2. Lora model selection

After selecting the large model, you actually have to choose the Lora model, because like the large model above, its function is only to draw realistic characters as much as possible, but if you want it to draw realistic + clay style characters, it is actually very difficult to do.

Without using Lora, the prompt words are:

clay,1man,black hair,

Generated images

Stable Diffusion tutorial, realize clay filter (special effect)

But sometimes you can get a slightly better one without Lora, like this

Stable Diffusion tutorial, realize clay filter (special effect)

Note: This picture is also generated by Tusheng

The Lora model can be found on Station C by typingclay keywords[1]You can

Stable Diffusion tutorial, realize clay filter (special effect)

The Lora model I chose here is CLAYMATE - Claymation Style for SDXL.

3. Select the image

Since we want to add a clay filter style to the picture this time, we choose a picture from the original image, and SD needs a picture as a reference. Although we didn't talk about the picture from the original image before, it is generally not much different from the picture from the original image.

4. Writing prompt words

My reference image this time is relatively simple, which is the picture of Sam Altman from OpenAI, so my positive prompt words are actually relatively simple:

clay,1man,black hair, ,

Clay means clay. This is the prompt word that triggers Lora. How is this obtained? In fact, it is also very simple. Just click on the corresponding Lora model (the prompt word area will be automatically displayed).

Stable Diffusion tutorial, realize clay filter (special effect)

Reverse prompt words (this depends on the situation):

lowres,bad anatomy,((bad hands)),(worst quality:2),(low quality:2),sketches,bad hands,text,error,missing fingers,

5. Sampling method

If you choose LEOSAM's HelloWorld XL as I did, the recommended sampling method is Eluer a, because this model is specifically suitable for Eluer a, which is mentioned in the model's page description, but you can also try DPM++ 2M Karras, which I tried and it works OK

6. Iteration steps

After I tried this, 25-30 steps are generally more suitable

7. Redraw size

Since the reference images have different sizes, using a fixed size may not match the style of the original image. Therefore, it is generally recommended to use the same size (or the same proportion) as the original image. Here is a little trick. Click here to keep the width and height consistent with the reference image.

Stable Diffusion tutorial, realize clay filter (special effect)

8. Prompt word coefficient

This has been discussed before. It determines the influence (weight) of the prompt word on the drawing. I chose 7.

9. Redraw range

This parameter is very important and is not included in the Wensheng graph. It represents the similarity between the generated image and the reference image. The range is 0-1. The smaller the value, the closer it is to the original image, and the larger the value, the farther it is from the original image. Generally, 0.5-0.7 is selected.

The above are the models and key parameters needed to generate the clay filter. Here are some of the renderings I generated:

Stable Diffusion tutorial, realize clay filter (special effect)
Stable Diffusion tutorial, realize clay filter (special effect)

What do you think of the effect produced by this clay filter?

statement:The content is collected from various media platforms such as public websites. If the included content infringes on your rights, please contact us by email and we will deal with it as soon as possible.
Encyclopedia

What are some useful AI tools? 6 free AI tools recommended to make your work more efficient!

2024-5-27 9:55:50

TutorialEncyclopedia

Open source large model Llama3 local deployment tutorial, build a personal knowledge base

2024-5-27 12:36:00

Search