Stable Diffusion应用:deliberate 您所在的位置:网站首页 pattern固定搭配 Stable Diffusion应用:deliberate

Stable Diffusion应用:deliberate

2023-03-23 13:23| 来源: 网络整理| 查看: 265

前言

Stable Diffusion捏人是答主自《上古卷轴5:天际》后见过的最复杂的工作。人物模型的调试修正不亚于一次次化学实验,从另一种角度来思考:这就是“人体炼成”,通过这段时间的反复摸索,算是有一点小小心得,或者说模板写作技巧。

本篇运用的是deliberate_v2模型,来自Civitai,没有加载其他的混合模型

一、反向提示词

这一部分非常重要,套一些大神给出来的模板,多尝试几回就能知道效果,而且一用上就比较稳定,后续需要修改的机会不多:

(((canvas frame))), cartoon, 3d, ((disfigured)), ((bad art)), ((deformed)),((extra limbs)),((close up)),((b&w)), wierd colors, blurry, (((duplicate))), ((morbid)), ((mutilated)), [out of frame], extra fingers, mutated hands, ((poorly drawn hands)), ((poorly drawn face)), (((mutation))), (((deformed))), ((ugly)), blurry, ((bad anatomy)), (((bad proportions))), ((extra limbs)), cloned face, (((disfigured))), out of frame, ugly, extra limbs, (bad anatomy), gross proportions, (malformed limbs), ((missing arms)), ((missing legs)), (((extra arms))), (((extra legs))), mutated hands, (fused fingers), (too many fingers), (((long neck))), Photoshop, video game, ugly, tiling, poorly drawn hands, poorly drawn feet, poorly drawn face, out of frame, mutation, mutated, extra limbs, extra legs, extra arms, disfigured, deformed, cross-eye, body out of frame, blurry, bad art, bad anatomy, 3d render二、正面提示词:基准模型的获取

正面提示词是捏人的核心,这里推荐使用分行写法,每一行代表对某些画面属性的设置,这一部分别的作者也有很多的教程,我这里就一个基准模型来作简要说明:

首先是模型采样方法、步数、画布大小的参数,这些参数设置好后可以保持固定:

Steps: 25, Sampler: Euler a, CFG scale: 7, Seed: 3016098831, Size: 768x1024

然后是正面提示词:

modelshoot style,(A beautiful Russian Girl:1.15),(Actress:1.3),20 Age,(Plump:0)(Buxom:0),(ultra quality:1.3),(masterpiece:1.3),(cinematography:1.4),(photorealistic:1.4),intricate elegant,(Utral-detailed:1.3),sharp focus, dramatic, (Pixie Cut hair:1.1),(Silver hair:1.05),(golden hair:1.05),hair decoration, (looking at viewer:1.25),(Green eyes:1.05),makeup,necklace,earings, smile,Closed lips, (See-through:0),(Grey:1.1),(Cyan:1.1),(blazer outer)(shirt inner:1.05)(straight skirt:1.05),(high split end:0.9),(Openwork pattern:0)(flower texture:0.8), (high-heeled shoes:1.22), (In the Gallery),(screen windows background:1.15), (full body shot:1.3),((dynamic lighting,depth of field)),Wide angle view

每一行提示词后面都会有一个逗号,

modelshoot style,(A beautiful Russian Girl:1.15),(Actress:1.3),20 Age,(Plump:0)(Buxom:0),(ultra quality:1.3),(masterpiece:1.3),(cinematography:1.4),(photorealistic:1.4),intricate elegant,(Utral-detailed:1.3),sharp focus, dramatic,

第一行设定人物的摄影模式,人物大致属性(Russian Girl),括号表示权重加强,冒号后面的数值表权重,数字小于1表减少权重,大于1表增加权重,增加权重最好在(1.1-1.4)这个区间内选择,每次调节到小数点后两位。这里注意,权重为0不代表图片里不带这个属性,某个属性你不想要最好将其删除。Buxom和Plump都是描述人物丰满程度的词。

后面的(ultra quality:1.3),(masterpiece:1.3),(cinematography:1.4),(photorealistic:1.4)都是表达画质的提示词,生成极高质量、电影质感的写实照片,等等

(Pixie Cut hair:1.1),(Silver hair:1.05),(golden hair:1.05),hair decoration,

第二行描述人物发型、发色、头饰的内容,在混合配色方面,如果不加权重值,一般靠前的色彩会占主导地位,但对靠后的色彩赋予一个较大的权重后也能“反杀”,不过值得注意的是,如果是随机生成种子(-1),则每次出的图发色都会有所不同。

(looking at viewer:1.25),(Green eyes:1.05),makeup,necklace,earings, smile,Closed lips,

第三行和第四行描述人物视线、脸部妆容面部表情等。

(See-through:0),(Grey:1.1),(Cyan:1.1),(blazer outer)(shirt inner:1.05)(straight skirt:1.05),(high split end:0.9),(Openwork pattern:0)(flower texture:0.8),

第五行是对服装属性的描述。

(See-through):服装透明度设置 (blazer outer):外套 (shirt inner:1.05):内衬 (straight skirt:1.05):下身服装 (high split end:0.9):裙装开衩 (Openwork pattern:0):服装镂空 (flower texture:0.8):服装花纹样式

第六行是对鞋的属性配置,这部分也会与摄影模式的提示词产生联动影响。

(high-heeled shoes:1.22),

第七和第八行是对布景还有景深灯光效果摄影角度的设置,答主非摄影爱好者,所以平时不太动这部分的配置。

(In the Gallery),(screen windows background:1.15), (full body shot:1.3),((dynamic lighting,depth of field)),Wide angle view

注意第八行的(full body shot)提示词,通常与第一行的Shoot style以及第六行的鞋属性配合使用。

下面是上述提示词画出来的人物,一般都是用随机种子生成,得到较好的模型后可以继续用同一个种子数来生成。

初始的模型,动作很怪异,never mind三、进阶修饰:提示词替换、搭配与权重微调1.摄影模式调节(全身、似半身、特写)

整体而言,全身像可以适当调高鞋属性的权重、相当于拉远镜头,而半身像和特写则强调面部细节(Face detailed),调节摄影模式一般可以选用这些关键词搭配:

全身像:modelshoot style+(high-heeled shoes↑)+ full body shot↑(效果参照上图)

近身像:portrait(替换modelshoot style)+(Face detailed↑)+(high-heeled shoes↓)+cowboy shot↑

portrait+(Face detailed:1.2)+(high-heeled shoes:0.8)+(cowboy shot:1.3)

特写照:portrait+(Face detailed↑)+(high-heeled shoes↓)+close-up shot↑

需要注意的是close-up有时候会将镜头贴的太近,反而会看不到人脸,这时候可以适当降低close-up权重到1.25左右,这样虽然人物部分头发被遮挡,但能看到妆容与表情,同理cowboy shot增大权重到一定程度,如1.4,也不会产生遮头发的图像,两种模式都有一个合理区间,需要自己探索。

portrait+(Face detailed:1.2)+(high-heeled shoes:0.8)+(close-up shot:1.25)2.服装颜色调节

这一部分能做到的只是调节权重,但不建议为每个服装部件都指定颜色,因为提示词之间也会相互“污染”,提示词的大原则:力求精简、切勿面面俱到,否则“写多错多”,不过多尝试总是没错的,毕竟捏人的乐趣就在于反复实验。在实操中,只要提示词有的颜色,都会有一定几率“跑偏”到别的物品上。

(Grey:1.1),(Cyan:1.1)(Grey:1.1),(Light red:1.3)(Grey:1.1),(Light red:1.1),发色的golden跑到裙子这里来了3.服装纹样配置

这一部分主要设置(Openwork pattern)与 (flower texture)两种属性。

(Openwork pattern:1.25)(flower texture:0.8),外套出现镂空效果(Openwork pattern:0)(flower texture:1.2),裙子上出现了花纹

除此之外,还有(See-through)属性,不过据测试在正式服装中效果不明显,反而是一些礼服类的服装效果相对突出,如maxi、qipao、cheongsam、ball gown、mermaid dress、mandarin gown等等。

4.DLC:描述性提示词的获取

接触了Stable Diffusion后无意中发现,中国日报(China Daily)的网站上有很多关于人物穿搭的教学,感叹学英语还是很重要的。



【本文地址】

公司简介

联系我们

今日新闻

    推荐新闻

    专题文章
      CopyRight 2018-2019 实验室设备网 版权所有