Stable-Diffusion-ebsynth-utility短片轉動畫

Stable Diffusion-ebsynth utility下載安裝
Stable Diffusion-ebsynth utility下載安裝
EbSynth生成過渡幀
EbSynth生成過渡幀
transparent-background遮罩
transparent-background遮罩
FFmpeg BIN設定指南
FFmpeg BIN設定指南

ebsynth-utility短片轉動畫,係開工之前,需准备架餐.

  1. EbSynth
  2. Ebsynth_Utility
  3. FFmpeg BIN設定指南
  4. transparent-background遮罩
  5. 首先建立工程project資料夾, 以『a~z/A~Z』起名,『吉格』以『-』替换.
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\input
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\output
  1. 係input下擺影片
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\input\model.mp4
  1. 著『stable diffusion webui』

 

 

 

 

  1. 撳『Ebsynth Utility』->『stage1』分幀同埋遮罩
  2. 『Project directory』工程資料夾路徑,吉資料夾.
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\output
  1. 『Original Movie Path』填影片路徑
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\input\model.mp4
  1. 撳『Configuration』->『stage1』
  2. 『Frame Width』『Frame Height』填『-1』,與影片寬高臺致.
  3. 『Mask Threshold』遮罩閾值『0~0.1』ࣿ
  4. 撳『Generate』生成『video_frame』分幀『video_mask』遮罩.
  5. 『video_frame』分幀
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\output\video_frame
  1. 『video_mask』輸出幀遮罩
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\output\video_mask

 

 

 

  1. 撳『Ebsynth Utility』->『stage2』生成關鍵幀
  2. 撳『Configuration』->『stage2』
  3. 『Minimum keyframe gap』最细關鍵幀間隔,默認
  4. 『Maximum keyframe gap』最大關鍵幀間隔,默認
  5. 『Threshold of delta frame edge』幀邊緣檢測閾值. 默認5
  6. 撳『Generate』复制關鍵幀『video_key』
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\output\video_key

 

 

 

  1. 撳『Ebsynth Utility』->『stage3』轉二元.
  2. 『Stable Diffusion checkpoint』揀貳次元模型『safetensors』
  3. 撳『img2img』
  4. 『prompt』咒詞
Masterpiece,Ultra high res,High quality,4k,(Photorealistic:1.2),Photo,Miniskirt,Breasts,large breasts,Navel,Lace,
  1. 『Negative prompt』反向咒詞
(worst quality:2), (low quality:2), (normal quality:2),lowres,((monochrome)),((grayscale)), (monochrome), skin spots, acnes, skin blemishes, age spot, glans,extra limbs,extra arms,extra legs,extra leg,extra foot,extra fingers,fewer fingers,strange fingers,missing arms,missing legs,missing fingers,fused fingers,too many fingers,bad hand,(bad_prompt:0.8), bad anatomy,bad hands, bad feet,bad body,bad proportions,gross proportions,DeepNegative,(fat:1.2),looking away,tilted head,{Multiple people},text,error,extra digit,fewer digits,cropped,jpeg artifacts,signature,watermark,username,blurry,cropped,poorly drawn hands,poorly drawn face,mutation,deformed,malformed limbs,long neck,cross-eyed,mutated hands,polar lowres,
  1. 『Resize by』->『WIDTH』『HEIGHT』與原片寛高壹致.
  2. 『Denoising strength重绘幅度』值細於『5』值越細圖像與原圖越似.
  3. 『SEED』随機種子.随意填固定值,例『123』.
  4. 係『script脚本』揀『ebsynth utility』
  5. 係『Project directory』填工程路徑.
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\output
  1. 係『Mask option (Override img2img Mask mode)』遮罩揀『Normal』
  2. 係『Inpaint Area(Override img2img Inpaint area)』揀『Only masked』僅重繪遮罩.
  3. 『Control Net Weight』权重『5』
  4. 『Control Net Weight For Face』face权重『5』
  5. 勾『Use Preprocess image If exists in /controlnet_preprocess』
  6. 撳『Settings』->『ControlNet』 .
  7. 勾『Allow other script to control this extension』允许 ControlNet 畀其它脚本调用.
  8. 『Apply settings』應用設定.
  9. 撳『img2img』->『Generate』生成『controlnet_input』同埋『img2img_key』
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\output\img2img_key

 

 

  1. 撳『Ebsynth Utility』->『5』校色
  2. 撳『Color Transfer Method』揀『default』
  3. 撳『Color Matcher Ref Image Type』揀『original video frame』
  4. 撳『Generate』生成撳『st3_5_backup_img2img_key』

 

 

  1. 撳『Ebsynth Utility』->『stage4』放大關鍵幀
  2. 撳『Settings』->『Saving images/grids』
  3. 勾『Use original name for output filename during batch process in extras tab』. 原始名稱作為輸出檔名
  4. 撳『Apply settings』應用設定.
  5. 撳『extrans』->『Batch from Directory』從資料㚒批次處理
  6. 『Input directory』輸入資料㚒
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\output\img2img_key
  1. 『Output directory』輸出資料㚒
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\output\img2img_upscale_key
  1. 『Upscaler1』揀『4x-UltraSharp』
  2. 『Scale By』揀『1』
  3. 撳『extrans』->『Generate』生成『img2img_upscale_key』放大關鍵幀.

 

 

 

 

  1. 撳『Ebsynth Utility』->『stage5』生成ebs文檔.
  2. 撳『Generate』生成ebs文檔.
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\xxxxx.ebs

 

 

 

  1. 撳『Ebsynth Utility』->『stage6』生成過度幀.
  2. 著『Ebsynth』載入『ebs』,頁眉顯示當前EBS檔名.
  3. 撳『Run All』生成『out』
  4. Ebsynth 過渡幀狀態變成 Synth後,依次載入『ebs』『00002.ebs』『00003.ebs』…重复上述两步.
Z:\Bookcard\Stable-Diffusion-ebsynth-utility\out-…

 

 

 

  1. 撳『Ebsynth Utility』->『stage7』合成短片.
  2. 『Crossfade blend rate』速率填
  3. 『Export type』可揀『mp4』『webm』『gif』『rawvideo』.
  4. 撳『Generate』生成两條片壹條有聲壹條冇聲.

 

 

 

 

  1. 撳『Ebsynth Utility』->『stage8』替換背景.
  2. 『Background source』背景可揀『圖』或『短片』
  3. 『Background type』可揀『Fit video length』或『LOOP』

 

 

正面咒詞
Masterpiece, 傑作
Ultra high res, 超高解像
High quality, 高品質
4k, 4k
(Photorealistic:1.2), 真實感
Photo, 相片
Miniskirt, 迷你裙
Breasts, 胸部
large breasts, 大乳
Navel, 肚臍
Lace, 蕾絲
WHITE LACE, 白色蕾絲
a girl with Tulle skirt, 薄紗裙
a girl with Lace blouse, 蕾絲襯衫

 

反向咒語Negative Prompt 簡述
(worst quality:2), 低質內容
(low quality:2), 低質內容
(normal quality:2), 低質內容
lowres, 低質內容
((monochrome)), 黑白
((grayscale)), 灰階
(monochrome), 單色
skin spots, 皮膚斑點
acnes, 痤瘡
skin blemishes, 皮膚瑕疵
age spot, 老人斑
glans, 龜頭
extra limbs, 多餘肢體
extra arms, 額外武器
extra legs, 多餘腳瓜瓤
extra leg, 多餘腳瓜瓤,
extra foot, 多餘腳掌
extra fingers, 手指太多
fewer fingers, 手指更少
strange fingers, 怪手指
missing arms, 缺手瓜
missing legs, 缺腳瓜瓤
missing fingers, 缺手指
fused fingers, 融合手指
too many fingers, 手指太多
bad hand, 歪手
(bad_prompt:0.8), 不良提示
bad anatomy, 解剖不良
bad hands, 歪手
bad feet,
bad body, 歪身歪勢,
bad proportions, 身體比例差,
gross proportions, 總比例
DeepNegative, 深度負面
(fat:1.2), 脂肪
looking away, 睇向別處
tilted head, 側頭
{Multiple people}, 多人
text, 文字
error, 錯字
extra digit, 額外數字
fewer digits, 細數
cropped, 裁剪
jpeg artifacts, 壓縮痕跡
signature, 簽名
watermark, 水印
username, 身份
blurry, 模糊
cropped, 裁剪
poorly drawn hands, 手畫得吾靚
poorly drawn face, 樣畫得吾靚
mutation, 突變
deformed, 變形
malformed limbs, 肢體畸形
long neck, 長頸
cross-eyed, 鬥雞眼
mutated hands, 手型變異
polar lowres, 極地低氣壓

 

 

Stable Diffusion-ebsynth utility下載安裝

Stable Diffusion-ebsynth utility下載安裝
Stable Diffusion-ebsynth utility下載安裝

Ebsynth Utility係Ebsynth 配套『Stable Diffusion』插件. 將短片分割幀,利用貳次元模型進行風格轉换.

https://github.com/s9roll7/ebsynth_utility.git

下載插件:

  1. 撳『Extensions擴展』->『Install from URL係網裝』
  2. 『URL for extension’s git repository』填『https://github.com/Mikubill/sd-webui-controlnet
https://github.com/Mikubill/sd-webui-controlnet.git
  1. 撳『Install』下載
  2. 撳『Extensions擴展』->『Installed已裝』
  3. 撳『Apply and restart UI應用後重啟界面』
  4. 係『txt2img』『img2img』下側『ControlNet』
  5. 如果出錯刪下列資料夾,在重新下載
C:\stable-diffusion-webui\extensions\ebsynth_utility
C:\stable-diffusion-webui\tmp\ebsynth_utility

 

transparent-background遮罩

transparent-background遮罩
transparent-background遮罩

transparent-background』自動分離人像同背景,再生成遮罩,冇需人手干預.

https://github.com/plemeri/transparent-background

登入『命令行模式CMD』, 進入資料夾Python.

CD C:\Program Files\Python310\

下載安裝『transparent-background』1.3.2版,

python.exe -m pip install transparent-background==1.3.2

裝1.3.3版係產生’fast’錯設

remover = Remover(fast=tb_use_fast_mode, jit=tb_use_jit, device=devices.get_optimal_device_name())
TypeError: Remover.init() got an unexpected keyword argument ‘fast’

卸裝『transparent-background』

pip uninstall transparent-background

可能需要更新python

python.exe -m pip install –upgrade pip

顯列python安装包及版本號.

Pip list

下載模型『ckpt_base.pth』『ckpt_fast.pth』『ckpt_base_nightly.pth

https://github.com/plemeri/transparent-background/releases/tag/1.2.12
https://github.com/plemeri/transparent-background/releases/download/1.2.12/ckpt_base.pth
https://github.com/plemeri/transparent-background/releases/download/1.2.12/ckpt_fast.pth
https://github.com/plemeri/transparent-background/releases/download/1.2.12/ckpt_base_nightly.pth

下載後擺係『C:\Users\user.transparent-background』

佢有圖形版『transparent-background-gui.exe』壹建生成遮罩.

C:\Program Files\Python310\Scripts\transparent-background-gui.exe
  1. 撳『open file』載入圖檔.
  2. 勾『reverse』反轉遮罩.
  3. 撳『process』生成遮罩.

 

如果『pydantic』報錯可先卸载後重装

ImportError: cannot import name ‘ValidationInfo’ from ‘pydantic’ (C:\Users\bookc\AppData\Roaming\Python\Python310\site-packages\pydantic\__init__.cp310-win_amd64.pyd)

先卸载『pydantic』

python.exe -m pip uninstall pydantic

後重装『pydantic』

python.exe -m pip install pydantic==1.8.1

 

FFmpeg BIN設定指南

FFmpeg BIN設定指南
FFmpeg BIN設定指南
  1. 登錄錄官網FFmpeg
https://ffmpeg.org/download.html
  1. 撳『Windows』
  2. 撳『Windows Builds by Btbn』
  3. 下載『ffmpeg-master-latest-win64-gpl.zip
https://github.com/BtbN/FFmpeg-Builds/releases/download/latest/ffmpeg-master-latest-win64-gpl.zip
  1. 解壓後擺係C碟,下有bin資料夾.
C:\ffmpeg-master-latest-win64-gpl\bin

三大神器

ffmpeg.exe 音影轉碼
ffplay.exe 播放機
ffprobe.exe 多媒体码流分析

 

添增環境路徑.

  1. 撳『win+Pause break』鍵
  2. 撳『進階系統設定』
  3. 撳『環境變數』
  4. 係『系統變數』->編輯『Path』->撳『新增』.
C:\ffmpeg-master-latest-win64-gpl\bin

 

Stable Diffusion顯卡吾支持半精度浮點數

Stable Diffusion顯卡吾支持半精度浮點數
Stable Diffusion顯卡吾支持半精度浮點數

『nvidia 2080ti』吾支持半精度類型, 早知買『nvidia 3090ti』

   modules.devices.NansException: A tensor with NaNs was produced in Unet. This could be either because there’s not enough precision to represent the picture, or because your video card does not support half type. Try setting the “Upcast cross attention layer to float32” option in Settings > Stable Diffusion or using the –no-half commandline argument to fix this. Use –disable-nan-check commandline argument to disable this check.
A tensor with all NaNs was produced in VAE.

Web UI will now convert VAE into 32-bit float and retry.

To disable this behavior, disable the ‘Automatically revert VAE to 32-bit floats’ setting.

To always start with 32-bit VAE, use –no-half-vae commandline flag.

  1. 𢴇行『webui-user.bat』著『Stable Diffusion webui』
  2. 撳『Settings』->『Stable Diffusion』
  3. 勾『Upcast cross attention layer to float32』
  4. 撳『Apply settings』應用設定
  5. 撳『Reload UI』重啟界面

 

另壹條橋係加入命令行參數

  1. 編緝『C:\stable-diffusion-webui\webui-user.bat』
  2. 係命令行參數『COMMANDLINE_ARGS』加入『–no-half』冇半精度類型, -『-no-half-vae』『–disable-nan-check』禁nan檢驗.
webui-user.bat
set COMMANDLINE_ARGS= –no-half  –no-half-vae  –disable-nan-check

 

–no-half-vae 吾將VAE模型切換成16bit浮點數
–no-half 吾將模型切換成16bit浮點數
–disable-nan-check 吾檢查生成圖像潛在空間是否包含nan值,係持續集成中運行時無需檢查點

 

Stable Diffusion-Openpose

Stable Diffusion-Openpose
Stable Diffusion-Openpose

『Openpose』直接控制姿势同埋表情.對人像動作控制大大提升.

首先獲得骨架姿勢『pose.json』

  1. 撳『txt2img』
  2. 撳『ControlNet Unit 0』
  3. 『Control Type』揀『OpenPose』
  4. 係『image』上傳人像圖.
  5. 『Preprocessor』揀『dw_openpose_full』獲得姿势表情.小量人像圖揀『openpose_full』.
  6. 『Model』揀『kohya_controllllite_xl_openpose_anime_v2 [b0fa10bb] 』
  7. 勾『Enable』使能.
  8. 勾『Pixel Perfect』像數完美
  9. 勾『Allow Preview』 允許預覽
  10. 撳『JSON』下載骨架姿勢『json』

 

依據骨架生成圖畫.

  1. 『Stable Diffusion checkpoint』揀『safetensors』或『waiREALMIX_v100.safetensors』
  2. 撳『txt2img文生圖』
  3. 填『正向咒語Prompt』
  4. 填『反向咒語Negative Prompt』
  5. 『Sampling method』揀『DPM++ 2S a』.
  6. 『Sampling steps 』填
  7. 『Width』填1600,『height』填
  8. 撳『ControlNet Unit 0』
  9. 『Control Type』揀『OpenPose』
  10. 勾『Enable』使能.
  11. 勾『Pixel Perfect』像數完美.
  12. 勾『Allow Preview』允許預覽.
  13. 撳『Upload JSON』上傳骨架姿勢『json』.
  14. 『Preprocessor』揀『dw_openpose_full』.
  15. 『Model』揀『thibaud_xl_openpose』.
  16. 『Control mode』揀『balanced平衡』.
  17. 撳『Generation』生成

 

正向咒語Prompt 簡述
1girl, 1女
solo, 獨奏
long hair, 長髮
breasts, 乳房
towel, 毛巾
cleavage, 卵裂
very long hair, 很長頭髮
naked towel, 裸毛巾
brown eyes, 棕色眼睛
large breasts, 大乳
hair between eyes, 眼睛之間頭髮
upper body, 上身
looking at viewer, 看著觀眾
bangs, 劉海
bare shoulders, 裸肩
tile wall, 瓷磚牆
collarbone, 鎖骨
brown hair, 棕髮
indoors, 室內
parted lips, 張開嘴唇
ahoge,

 

反向咒語Negative Prompt 簡述
(worst quality:2), 低質內容
(low quality:2), 低質內容
(normal quality:2), 低質內容
lowres, 低質內容
((monochrome)), 黑白
((grayscale)), 灰階
(monochrome), 單色
skin spots, 皮膚斑點
acnes, 痤瘡
skin blemishes, 皮膚瑕疵
age spot, 老人斑
glans, 龜頭
extra limbs, 多餘肢體
extra arms, 額外武器
extra legs, 多餘腳瓜瓤
extra leg, 多餘腳瓜瓤,
extra foot, 多餘腳掌
extra fingers, 手指太多
fewer fingers, 手指更少
strange fingers, 怪手指
missing arms, 缺手瓜
missing legs, 缺腳瓜瓤
missing fingers, 缺手指
fused fingers, 融合手指
too many fingers, 手指太多
bad hand, 歪手
(bad_prompt:0.8), 不良提示
bad anatomy, 解剖不良
bad hands, 歪手
bad feet,
bad body, 歪身歪勢,
bad proportions, 身體比例差,
gross proportions, 總比例
DeepNegative, 深度負面
(fat:1.2), 脂肪
looking away, 睇向別處
tilted head, 側頭
{Multiple people}, 多人
text, 文字
error, 錯字
extra digit, 額外數字
fewer digits, 細數
cropped, 裁剪
jpeg artifacts, 壓縮痕跡
signature, 簽名
watermark, 水印
username, 身份
blurry, 模糊
cropped, 裁剪
poorly drawn hands, 手畫得吾靚
poorly drawn face, 樣畫得吾靚
mutation, 突變
deformed, 變形
malformed limbs, 肢體畸形
long neck, 長頸
cross-eyed, 鬥雞眼
mutated hands, 手型變異
polar lowres, 極地低氣壓

 

 

https://github.com/huchenlei/sd-webui-openpose-editor.git

 

 

Stable Diffusion動畫轉真人

Stable Diffusion動畫轉真人
Stable Diffusion動畫轉真人
Stable Diffusion動畫轉真人
Stable Diffusion動畫轉真人

『Stable Diffusion』真人改動畫, 重點係揀適合模型,同埋設較細重绘幅度.

  1. 撳『Tagger』反推咒語引導生圖.
  2. 『Stable Diffusion checkpoint』模型揀『safetensors』.
  3. 撳『img2img文生圖』.
  4. 撳『Generation』->『img2img』
  5. 係『IMAGE』拖入動畫.
  6. 『Resize mode』揀『Resize and fill』.
  7. 『Sampling method采樣法』揀『DPM++ 2S a』.
  8. 『Sampling steps采樣步』填『32』.
  9. 『Resize BY』->『SCALE缩放』填 與原圖大細壹致.
  10. 『Denoising strength重绘幅度』填『0.52』,值越細圖像與原圖越似.
  11. 撳『ControlNet unit0』
  12. 勾『Enable使能』
  13. 勾『Pixel Perfect』像數完美
  14. 勾『Allow Preview』允許預覽
  15. 勾『Upload independent control image』上傳獨立控制影像
  16. 揀『Single image』拖入動畫.
  17. 『Control Type』揀『openpose』
  18. 『Preprocessor』揀『dw_openpose_full』
  19. 『mode』揀『t2i_adapter_diffusers_xl_openpose』,openpose模型須與基礎模型相配.
  20. 『Control mode』揀『balanced平衡』
  21. 『Resize mode』揀『Resize and fill』.
  22. 撳『Generate』生成影像.

 

正向咒語Prompt 簡述
1girl, 1女
solo, 獨奏
long hair, 長髮
breasts, 乳房
towel, 毛巾
cleavage, 卵裂
very long hair, 很長頭髮
naked towel, 裸毛巾
brown eyes, 棕色眼睛
large breasts, 大乳
hair between eyes, 眼睛之間頭髮
upper body, 上身
looking at viewer, 看著觀眾
bangs, 劉海
bare shoulders, 裸肩
tile wall, 瓷磚牆
collarbone, 鎖骨
brown hair, 棕髮
indoors, 室內
parted lips, 張開嘴唇
ahoge,

 

反向咒語Negative Prompt 簡述
(worst quality:2), 低質內容
(low quality:2), 低質內容
(normal quality:2), 低質內容
lowres, 低質內容
((monochrome)), 黑白
((grayscale)), 灰階
(monochrome), 單色
skin spots, 皮膚斑點
acnes, 痤瘡
skin blemishes, 皮膚瑕疵
age spot, 老人斑
glans, 龜頭
extra limbs, 多餘肢體
extra arms, 額外武器
extra legs, 多餘腳瓜瓤
extra leg, 多餘腳瓜瓤,
extra foot, 多餘腳掌
extra fingers, 手指太多
fewer fingers, 手指更少
strange fingers, 怪手指
missing arms, 缺手瓜
missing legs, 缺腳瓜瓤
missing fingers, 缺手指
fused fingers, 融合手指
too many fingers, 手指太多
bad hand, 歪手
(bad_prompt:0.8), 不良提示
bad anatomy, 解剖不良
bad hands, 歪手
bad feet,
bad body, 歪身歪勢,
bad proportions, 身體比例差,
gross proportions, 總比例
DeepNegative, 深度負面
(fat:1.2), 脂肪
looking away, 睇向別處
tilted head, 側頭
{Multiple people}, 多人
text, 文字
error, 錯字
extra digit, 額外數字
fewer digits, 細數
cropped, 裁剪
jpeg artifacts, 壓縮痕跡
signature, 簽名
watermark, 水印
username, 身份
blurry, 模糊
cropped, 裁剪
poorly drawn hands, 手畫得吾靚
poorly drawn face, 樣畫得吾靚
mutation, 突變
deformed, 變形
malformed limbs, 肢體畸形
long neck, 長頸
cross-eyed, 鬥雞眼
mutated hands, 手型變異
polar lowres, 極地低氣壓

 

Stable Diffusion-升级XL模型

Stable Diffusion-升级XL模型
Stable Diffusion-升级XL模型
Stable Diffusion-升级XL模型
Stable Diffusion-升级XL模型
Stable Diffusion-升级XL模型
Stable Diffusion-升级XL模型
Stable Diffusion-升级XL模型
Stable Diffusion-升级XL模型
Stable Diffusion-升级XL模型
Stable Diffusion-升级XL模型

继『Stable Diffusion 2.1』後推出『Stable Diffusion XL1.0』升级版,分三版『Base』『refiner』『turbo』.適用於『AUTOMATIC1111』

https://huggingface.co/stabilityai?search_models=xl

 

下載 XL 模型

https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0/resolve/main/sd_xl_base_1.0.safetensors?download=true
https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0/resolve/main/sd_xl_base_1.0_0.9vae.safetensors?download=true
https://huggingface.co/stabilityai/stable-diffusion-xl-refiner-1.0/resolve/main/sd_xl_refiner_1.0.safetensors?download=true
https://huggingface.co/stabilityai/stable-diffusion-xl-refiner-1.0/resolve/main/sd_xl_refiner_1.0_0.9vae.safetensors?download=true
https://huggingface.co/stabilityai/sdxl-turbo/resolve/main/sd_xl_turbo_1.0.safetensors?download=true
https://huggingface.co/stabilityai/sdxl-turbo/resolve/main/sd_xl_turbo_1.0_fp16.safetensors?download=true

擺係

C:\stable-diffusion-webui\models\Stable-diffusion

 

下載VAE模型

https://huggingface.co/stabilityai/sdxl-vae/resolve/main/sdxl_vae.safetensors?download=true

擺係

C:\stable-diffusion-webui\models\VAE

 

下載LORA模型

https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0/resolve/main/sd_xl_offset_example-lora_1.0.safetensors?download=true

擺係

C:\stable-diffusion-webui\models\Lora

 

SDXL 1.0 模型 簡述
sd_xl_base_1.0.safetensors base模型
sd_xl_base_1.0_0.9vae.safetensors base模型內置 VAE
sd_xl_refiner_1.0.safetensors refiner模型
sd_xl_refiner_1.0_0.9vae.safetensors refiner模型內置 VAE
sd_xl_turbo_1.0.safetensors turbo模型
sd_xl_turbo_1.0_fp16.safetensors turbo模型內置 VAE
sdxl_vae.safetensors 外置VAE模型
sd_xl_offset_example-lora_1.0.safetensors lora模型

 

網埞址 版本
https://huggingface.co/stabilityai?search_models=xl XL
https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0 base
https://huggingface.co/stabilityai/stable-diffusion-xl-refiner-1.0 refiner
https://huggingface.co/stabilityai/sdxl-turbo turbo
https://huggingface.co/ByteDance/SDXL-Lightning Lightning
https://huggingface.co/stabilityai/sdxl-vae VAE

Nvidia-2080ti吾支持float16精度,彈出警示.

A tensor with all NaNs was produced in VAE.

Web UI will now convert VAE into 32-bit float and retry.

To disable this behavior, disable the ‘Automatically revert VAE to 32-bit floats’ setting.

To always start with 32-bit VAE, use –no-half-vae commandline flag.

  1. 直接编緝『C:\stable-diffusion-webui\webui-user.bat』.
  2. 係『COMMANDLINE_ARGS』命令行参數加入『–no-half-vae』吾將VAE模型轉換為float-16bit半精度.
webui-user.bat
set COMMANDLINE_ARGS= –no-half-vae

 

–no-half-vae 吾將VAE模型轉換為float-16bit半精度
–no-half 吾將模型轉換為float-16bit半精度
–disable-nan-check 吾檢查生成圖像/潛在空間是否包含nan值,在持續集成中運行時無需檢查點

 

正咒詞  
looking at viewer, 睇著觀眾
making eye contact, 眼神交流
a girl with Tulle skirt, 薄紗裙
a girl with Lace blouse, 蕾絲襯衫
a girl Sequin dress, 亮片裙
Volumetric Lighting, 體積照明
light depth, 光深度
flower
beautiful lighting,  
Double Exposure Style, 雙重曝光風格
Traditional Attire, 傳統服飾
Artistic Calligraphy and Ink, 書法與水墨藝術
dramatic atmospheric lighting, 戲劇氛圍照明
Volumetric Lighting, 體積照明
double image ghost effect, 雙影像重影效果
image combination, 影像組合
double exposure style, 雙重曝光風格
   
   
1girl, 1女孩,
solo, 獨奏,
long hair, 長髮
breasts, 乳房
towel, 毛巾
cleavage, 卵裂
very long hair, 長髮
naked towel, 裸毛巾
brown eyes, 棕眼
large breasts, 大乳房
hair between eyes, 眼睛之間頭髮
upper body, 上身
looking at viewer, 看著觀眾
bangs, 劉海
bare shoulders, 裸露肩膀
collarbone, 鎖骨
brown hair, 棕髮
indoors, 室內
parted lips, 張開嘴唇

 

反咒詞  
ugly, 醜陋
deformed, 變形
noisy, 嘈雜
blurry, 模糊
low contrast, 低對比度

 

Stable Diffusion-放大算法4x-UltraSharp

Stable Diffusion-放大算法4x-UltraSharp
Stable Diffusion-放大算法4x-UltraSharp
Stable Diffusion-放大算法4x-UltraSharp
Stable Diffusion-放大算法4x-UltraSharp
Stable Diffusion-放大算法4x-UltraSharp
Stable Diffusion-放大算法4x-UltraSharp

『4x-UltraSharp』比『R-ESRGAN General 4xV3』放大效果仲清晰.冇損逼真放大.

  1. 下載『4x-UltraSharp』
https://huggingface.co/lokCX/4x-Ultrasharp/resolve/main/4x-UltraSharp.pth?download=true
https://huggingface.co/lokCX/4x-Ultrasharp/tree/main
  1. 擺係
C:\stable-diffusion-webui\models\ESRGAN
  1. 撳『Settings』->『Face restoration』.
  2. 禁『Restore faces面部修复』.
  3. 撳『Settings』->『user interface』.
  4. 係『Quicksettings list』加入『upacler_for_img2img』係頁頂快速設定放大算法.
  5. 撳『Apply settings』應用設定.
  6. 撳『Reload UI』重啟界面.
  7. 係頁頂『Upscaler for img2img』揀『4x-UltraSharp』.
  8. 撳『img2img』->『Generation』->『img2img』
  9. 拖入低解像圖畫
  10. 係『Resize by』->『Scale缩放』設『4』,如果記憶體溢出降低放大值.
  11. 係『Denoising strength』設值『1』
  12. 撳『Generate』放大圖畫.