How to use AI drawing to draw a young lady with a super realistic sense of detail? (Lora article)

Two days ago, I shared how to use the stable diffusion webui installation tutorial (mac chapter) , please see here for the win chapter .

Someone asked: The installation is complete, but why is there such a gap between the generated picture and the picture generated by you, the author?

How do the realism and texture match each other?

So, what is the difference between the picture I drew and the picture you drew?

The key factor is that I used a special generation model model and lora package.

Today we will talk about how to use the lora package to generate super realistic and beautiful character pictures with super texture.

one. tutorial section

1. You should have installed stable diffusion webui in your computer. If you haven’t installed it yet, please go back and install it before coming back, otherwise you won’t be able to use it. ( win installation tutorial , mac installation tutorial )

  1. Open http://civitai.com

Civitai is a community of AI drawing enthusiasts. There are many personalized models, especially 3D, reality, characters, painting styles and other targeted training models. Therefore, when you use a specific model to generate a painting of a specific theme, the expressiveness will be greatly enhanced.

(Note that direct access to this website is unstable, and may require magic to surf the Internet. In addition, it contains some nsfw content, and minors are prohibited from accessing it.)

3. Find the style picture you want to generate, check the detailed information and download the corresponding package and model.

Take the Korean Doll Likeness (Korean Doll Likeness) as an example.

(1) Download the lora package and put it in the specified folder

Click download in the upper right corner to download this Lora package. (Generally dozens to hundreds of MB), after downloading, put it under the stable-diffusion-webui > models > Lora folder on your computer.

(2) On the lora package web page, click the exclamation mark in the lower right corner of the sample picture to view the generated information.

(3) Find the model line, and understand that this lora package also needs to use the chilloutmix_cilloutmixNi model

(4) Download the model and put it in the specified folder

Put chilloutmix_cilloutmixNi on the Civitai search box and found no results, but found a similar model (checkpoint) that generates real portraits, called OrangeChillMix, and then we downloaded this model (7.17GB) and put it in stable- Diffusion-webui>models>Stable-diffusion folder.

4. Start stable-diffusino-webui and switch models

(1) Start the stable diffusion webui

How to start it will not be repeated. If you forget it, you can go back and read the win installation article and mac installation article. There are instructions on how to start it.

(2) switch model

First click the refresh button in the upper left corner, then click the down arrow in the upper left corner, find the orangechillmix_v70.safetensors model you just downloaded, and click it.

After waiting for a minute, press F5 to refresh the page. If the words "orangechillmix_v70.safetensors" are automatically displayed in the upper left corner, then the model switching is successful.

(Note, to switch the model, you need to complete the third step in advance: download the model and put it in the specified folder)

5. Start generating the image.

(1) The browser returns to the Korean Doll Likeness webpage just now, click the exclamation mark in the lower right corner of the sample picture, and click the copy generation data button.

(2) In the prompt input box of the stable diffusion webui, Ctrl (command) + V, paste the content just copied, and then click the "lower left arrow" under Generate.

At this time, you will find that the long prompt has become shorter, where is the other content?

It turns out that I went to the nagative prompt box below, and the following parameter configuration.

[External link picture transfer failed, the source site may have an anti-theft link mechanism, it is recommended to save the picture and upload it directly (img-2HJGKwIT-1678168834801)(https://p3-juejin.byteimg.com/tos-cn-i-k3u1fbpfcp /8a9ff20b2efd43e68d3f3c4217449817~tplv-k3u1fbpfcp-zoom-1.image)]

(3) Click generate to start generating images.

(4) Wait for the image to be generated, then right-click the generated image to save, or click the folder icon below the image to enter the folder to view the generated image.

two. Answer questions

Question 1. According to the steps mentioned above, what should I do if I find that the generated image is very slow? For example, if you look at the following, it takes more than 20 minutes or even longer to generate a picture?

answer:

This is due to the insufficient performance of the computer, resulting in too slow calculation. The example images are all of the default graphics card performance is very strong, so for you, the options they have may be too computationally intensive and the generation time is super slow.

Just like when we watch game promotional videos, they are usually very smooth and the picture quality is super exquisite, but when we play by ourselves, due to insufficient configuration, it may be laggy and blurry, which is the same reason.

So if your computer performance is insufficient, how to optimize the speed? (Of course, the drawing quality/effect will also be discounted)

(1) Uncheck hire.fix. This function is to expand the resolution and enhance the image quality, which consumes a lot of computing power;

(2) If the resolution is 512 768, you don't need to change it. If it is 768 1024 or above 768, then reduce the resolution proportionally. (What should I do if I want a high-definition image? After generating the basic image, use the extra function to enlarge the image. Follow me, I will talk about it later.)

(3) The sampling method sampling method, the original author is two, dpm++sde karras, can be changed to euler a

(4) Upgrade the hardware and buy a better graphics card, such as Nvidia GTX3060 or higher, with 12G video memory or higher.

(Note that the above methods do not necessarily need to be used all, if one or two can be used to improve the drawing speed, because the more changes are made, the greater the impact on the quality of the drawing results.)

Question 2. If I don’t use the lora bag of Miss Korean, what should I do with other bags?

Answer: Same as the above tutorial, first find a drawing type and style you are interested in, such as 3D, animation, national style or the like, click in to see which lora packages and models are used by the other party, and download the relevant models and lora packages. Can.

Question 3. How is the lora package reflected in the prompt?

answer:

Let's take a look at the lora prompt of a sample prompt:

It can be seen that the usual form of using the lora package is <lora:loraname_v1.x: 0.xx>, and multiple lora packages can be used together.

The first lora means that I want to use the lora package, the latter is the name and version of the lora package, and the last 0.xx is the proportion. The larger the number, the more obvious the characteristics of lora.

For example, the two lora packages in the example can be 0.6 and 0.4 respectively, or 0.3 and 0.7 respectively, and the sum should not exceed 1.

Question 4. What should I do if I use the lora package, terminal or cmd report an error saying that the name of Lora cannot be found?

answer:

If you report this error, you can also generate a graph, but you cannot apply and display the features of the lora package you want to use.

For example, the above error is that the lora package you specified was not found. At this time, either you have not downloaded the lora package, or the name of the lora package is wrong.

Click the image below the gerate button, then click lora, all the lora packages you have will be listed below, copy the name to replace the lora package name in the prompt area, and change the name to the correct one, no error will be reported, and the corresponding lora package features can be used up.

Question 5. What should I do if I want to generate the same face every time I have generated a good-looking lady?

answer:

(1) Try to use the same lora package as stably as possible;

(2) Keep the same seed unchanged

(3) "Alchemy" by yourself, training the face model lora package or checkpoint model library you want.

Guess you like

Origin blog.csdn.net/qq_44232564/article/details/129381297