◆1:ControlNet拡張機能を「Stable Diffusion web UI(AUTOMATIC1111版)」にインストール
「Stable Diffusion web UI(AUTOMATIC1111版)」を起動したら、
「拡張機能」をクリックしてから「URLからインストール」をクリックし、
URL入力欄に「https://github.com/Mikubill/sd-webui-controlnet」と入力して「インストール」をクリックします。
◆2:ControlNetのモデルデータをダウンロード
続いて、以下のリンク先にアクセスしてControlNetのモデルデータをダウンロードします。
webui/ControlNet-modules-safetensors at main https://huggingface.co/webui/ControlNet-modules-safetensors/tree/main
リンク先には、モデレーターがズラリと並んでいます。
今回は「ポーズを指定して画像生成」という機能を使いたいので「control_openpose-fp16.safetensors」をクリック。
>>28
以下のエラーが起こる場合、メッセージに従って、「settings」→「Stable-diffusion」の「Upcast cross attention layer to float32」にチェックを入れるとよいようです。
modules.devices.NansException: A tensor with all 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.
Stable Diffusion web UI(AUTOMATIC1111版)の場合
webui/models/Stable-diffusion へ上記モデルを移動
●プロンプト(=呪文)の基本的なコツ
プロンプト
very cute and beautiful girl, (アニメ風美少女のイラスト)
very cute and beautiful anime face and eyes (理想に近いアニメ風美少女のイラスト)
extremely beautiful detailed anime face and eyes (厚塗りタッチアニメ風美少女のイラスト)
school girl
maid girl
プロンプト
masterpiece, a very cute and beautiful girl, highly detailed face and eyes, clearly outlined, single character, beautiful blue hair, beautiful blue eyes, smile,1girl, sunlight, school uniform, background cherry blossoms and beautiful sky, spring, fold hands behind, dynamic pose, from above, standing,
・seedを固定(Seedの花びらボタンを押す) 同じ絵が出るようになる
・プロンプトの単語(birds など)を選択し、(Ctrl + ↑3回)で(birds:1.3)となり、目的画像を多く描き出せるようになる
・言葉を()で区切れば強調できるが、現在は(birds:1.3)「鳥の数を1.3倍に」という書き方が主流
・言葉を抑制したいときは(birds:0.5)などと書く
・[ ]大カッコは画像の差し替えを意味してしまうため、使用しない
[a girl : a dog :8]とすると、8ステップ目に画像が少女から犬に切り替わり、犬顔少女となる
・[cow | horse] in a field とすると、1ステップ毎にサンプル画像が牛と馬で切り替わり、合成した体形の動物となる
・a cat AND a dogとすると、猫犬が混ざった動物となる
「Stable Diffusion Web UI」で、「ChilloutMix」を使う
モデルデータ「Chilloutmix-Ni-pruned-fp32-fix.safetensors」を使う
プロンプト
head portrait, realistic, 1girl, eyes, loli, lots of frills, black long dress, starry sky, black hair blowing in the wind, trees, bloom light effect
Stable Diffusion web UI(AUTOMATIC1111版)でChilloutMixを使う
「chilloutmix_cilloutmixNi.safetensors」を「stable-diffusion-webui/models/Stable-diffusion」ディレクトリに設置します。