本文实战模型Automatic1111和Vlad Diffusion界面均适用。
ACG LoRA的写实风难题
用ACG图片训练出来的LoRA models,时有难以使用写实风checkpoints models绘制出满意成果的情况。
之前我会尝试先用ACG风格的checkpoint运算text2Image,再使用写实风的checkpoint运算image2image,不过结果往往不尽人意。
但ControlNet推出tile resample后,上述方式已成为能有效运用的方法了。
以下所有绘图成果的-Prompts均如下:
bad-hands-5, ng_deepnegative_v1_75t, (low quality, worst quality:1.4), (monochrome:1.1), (greyscale), watermark, text, blurry, jpeg artifacts, cropped, normal quality, signature, username, artist name, cartoon, canvas frame, lowres, (disfigured), (bad art), (deformed), (extra limbs), (b&w), weird colors, (duplicate), (morbid), (mutilated), mutated hands, (poorly drawn hands), (poorly drawn face), (mutation), (ugly), (bad proportions), cloned face, out of frame, gross proportions, (malformed limbs), (missing arms), (missing legs), (extra arms), (extra legs), fused fingers, (long neck), lowres, (grayscale), (skin spots), acnes, skin blemishes, (age spot),
*bad-hands-5
*ng_deepnegative_v1_75使用的checkpoint models有二:
写实风:FantasticMix
ACG风:SweetMix
使用的upscale演算法(放大演算法,会在HiresFix、Tiled Diffusion用到):4x_NMKD-Superscale-SP_178000_G,
下载「
4x_NMKD-Superscale-SP_178000_G.pth」文件后,请放到models\ESRGAN文件夹内。因审核原因,删除部分内容。。。
爱德(爱德华·爱力克)
LoRA下载地址:civitai.com/models/24114?modelVersionId=28813《钢链》的爱德就很难搞了,没办法像SpyXFamily的约儿能直接用Text2Image一次搞定。直接让大家看看用爱德LoRA + FantasticMix算出来的成果便能知道原因:
直接用FanstasticMix + Hires.fix的成果
+
ultra realistic 8k cg, masterpiece, ultra detailed background, delicate pattern, intricate detail, highly detailed, fine details, best quality, 1boy, flat chin, manly, (photorealistic:1.4), beautiful lighting, absurdres, Edward Elric, backlighting, black background, ((black jacket)), ((white gloves)), yellow hair, grin, cowboy shot, ((red hoody)), ((red coat)), light particles, hair braid, looking at viewer, yellow eyes, solo, RAW photo, film grain, <lora:edwardElricFullmetal_v3:1>,
Steps: 30
Sampler: Euler a
CFG scale: 5
Seed: 3400642652
Size: 512×768
Model: fantasticmix_v40
Denoising strength: 0.4
Hires.Fix upscale: 2
Hires.Fix upscaler: 4x_NMKD-Superscale-SP_178000_G
见鬼了,而且不知道为啥我觉得有点杨丽花(没有不敬的意思),变成像是富有英气的女角。我认为有这样的结果,可能的原因有下列两点:
热衷于Stable Diffusion的男性宅男数量远远超过女性宅女,导致人物类checkpoint models的训练非常偏重女性角色,尤其NSFW类的models更明显。爱德相较约儿更「卡通化」,也就是「更偏离现实的五官比例、形状和脸型」,导致写实风的checkpoint model「难以看懂」,无法妥当地转换为写实脸孔。……总之先和约儿一样如法炮制,保留所有设定但改用ACG风的SweetMix,不过这次我就先不用Hires.Fix了,因为根据经验接下来转写实风的步骤失败率会很高,不想先绘大图:
直接用SweetMix的成果
很不错,接着尝试用这张搭配tile resample,成果如下:
把SweetMix绘出来的图当作tile resample的参考图,使用FantasticMix绘出来的成果
……是没有那么像歌仔戏的英俊小生了,但还是不太行,尤其眼睛实在太大。这时我就想了,干脆来试试看ControlNet另一个新功能reference_only吧(仍保留相同设置,但seed改为随机):
改用reference_only搭配FantasticMix的成果,seed 1661784639
…….反而变得更糟了。这时我想说有没有可能是因为已经用ACG风的原图当参考了,还多重复了一次相同的正面提示词所导致,便干脆把正面提示词全空白再试一次:
改用reference_only、正面提示词留白,搭配FantasticMix的成果
……..结果不只变得像ACG风(毕竟参考了原图嘛)还转性了(也似乎证实了我的「偏重女角」推测)。不得不说转得还蛮可爱的,但这不是我想要的成果,所以我调整了正面提示词再做尝试:
是怎样?正面提示词中的「1boy」直接无视,硬要转性就对了?虽然是真的很会画女角…..
+
ultra realistic 8k cg, masterpiece, ultra detailed background, delicate pattern, intricate detail, highly detailed, fine details, best quality, 1boy, flat chin, manly, (photorealistic:1.4), beautiful lighting, absurdres,
正面提示词只加回爱德的LoRA指令……还是不行
+
<lora:edwardElricFullmetal_v3:1>
事实证明reference_only不是正确选择,还是得回到Tile Reample上,于是我回到使用原本的ACG风原图为Tile Resample的参考图搭配FantasticMix,但持续调整正面提示词和使用随机seed,终于获得一个还能接受的成果:
左眼的颜色原本偏深灰,这是手动调整后的版本。
+
ultra realistic 8k cg, masterpiece, best quality, 1boy, flat chin, manly, (photorealistic:1.4), beautiful lighting, absurdres, Edward Elric, <lora:edwardElricFullmetal_v3:1>, (cosplay), yellow eyes, red coat,
接着我将上图传到Image2Image放大,除了负面提示词都有略作调整,最后成果如下:
FantasticMix有点过度喜欢添加细节
+
ultra realistic 8k cg, masterpiece, best quality, 1boy, (((flat chin))), (((wide chin))), (((manly face))), (((mans face))), (muscular face), (photorealistic:1.4), beautiful lighting, absurdres, Edward Elric, <lora:edwardElricFullmetal_v3:0.1>, (cosplay), yellow eyes, red coat, RAW photo, film grain, <lora:add_detail:-1>, thin lips,
_
bad-hands-5, ng_deepnegative_v1_75t, (low quality, worst quality:1.4), (monochrome:1.1), (greyscale), watermark, text, blurry, jpeg artifacts, cropped, normal quality, signature, username, artist name, cartoon, canvas frame, lowres, (disfigured), (bad art), (deformed), (extra limbs), (b&w), weird colors, (duplicate), (morbid), (mutilated), mutated hands, (poorly drawn hands), (poorly drawn face), (mutation), (ugly), (bad proportions), cloned face, out of frame, gross proportions, (malformed limbs), (missing arms), (missing legs), (extra arms), (extra legs), fused fingers, (long neck), lowres, (grayscale), (skin spots), acnes, skin blemishes, (age spot), (((beard))), (((moustache))),
Steps: 30
Sampler: DPM++ 2S a Karras
CFG scale: 6
Seed: 2652740664
Size: 1024×1536
Model: fantasticmix_v40
Denoising strength: 0.5
Tiled Diffusion upscaler: 4x_NMKD-Superscale-SP_178000_G
Tiled Diffusion scale factor: 2
Tiled Diffusion: “{Method: Mixture of Diffusers, Tile tile width: 128, Tile tile height: 128, Tile Overlap: 24, Tile batch size: 1, Upscaler: 4x_NMKD-Superscale-SP_178000_G, Upscale factor: 2, Keep input size: True}”
ControlNet: “preprocessor: tile_resample, model: control_v11f1e_sd15_tile [a371b31b], weight: 1, starting/ending: (0, 1), resize mode: Crop and Resize, pixel perfect: True, control mode: Balanced, preprocessor params: (64, 1, 64)”
因为FantasticMix会过度增加细节,所以这里我使用了调整细节的LoRA尝试减少细节量,效果很不错,不过没法改掉衣服不必要的波浪边缘。
下载LoRA Detail Tweaker(细节调整):
civitai.com/models/58390/detail-tweaker-lora-lora*此LoRA是少数可以使用负权重的LoRA,负=减少细节,正=增加细节,数值在-2~2之间,例如<lora:add_detail:-1>。
另外,实际上嘴唇的部分有手动后制过,由以下正面提示词算出来的图取代:
+
ultra realistic 8k cg, masterpiece, best quality, 1boy, flat chin, manly, (photorealistic:1.4), beautiful lighting, absurdres, Edward Elric, <lora:edwardElricFullmetal_v3:1>, (cosplay), yellow eyes, red coat,
主要是爱德LoRA提示词的权重:<
lora:edwardElricFullmetal_v3:0.1>和<
lora:edwardElricFullmetal_v3:1>的差别。总结来说,比约儿要多花很多功夫,且成果可能还没有约儿的满意(依然有点像女性),好的方面则是成功使用了爱德的LoRA达成写实风的成果。
暂无评论内容