提示語法
Easy Diffusion 使用compel(提示解析庫)來支持用于圖像的提示中的權重和強調。
強調
將單詞或短語加上-或+,或加上0和2之間的權重(默認值為“1”),以減少或增加該單詞/短語在生成的圖像中的重要性。例如:man picking apricots+.男人 摘 杏子+。
您可以使用括號為多個單詞指定權重。例如a man (picking apricots)1.5或a man (picking apricots)++
您可以添加更多的+或-符號來進一步增加/減少權重。例如,apricots++比apricots+更重要,而apricots--的重要性比apricots-低。你可以使用多少個+或-符號是沒有限制的。
您還可以使用數字為單詞/短語分配準確的權重:
- A weight between
0and1.0reduces the importance of the token. For e.g.(apricots)0.5reduces the importance of apricots to half. - A weight between
1.0and2increases the importance of the token. For e.g.(apricots)1.5increases the importance of apricots by 1.5 times. - 權重介于
0和1.0之間的會降低令牌(token:實際大概是分詞處理后文本標記)的重要性。例如,(apricots)0.5將杏子的重要性降低一半。 - 權重介于
1.0和2之間的會會增加令牌的重要性。例如,(apricots)1.5杏子的重要性提高了 1.5 倍。
+本質上是 的權重1.1,并且-本質上是 的權重0.9。
更多示例
- 嵌套:
a tall thin man (picking apricots+)++(apricotseffectively gets+++) - 不帶括號的單個單詞:
a tall thin man picking apricots+ - 帶括號的單個或多個單詞:
a tall thin man (picking apricots)+a tall thin man picking (apricots)-a tall thin man (picking apricots)- - 更多符號帶來更多效果:
a tall thin man (picking apricots)++, 和a tall thin man (picking apricots)+++ - 以上所有內容均帶有明確的數字:
a tall thin man picking (apricots)1.1a tall thin man (picking (apricots)1.3)1.1. (+相當于 1.1、++is1.1 x 1.1、+++is1.1 x 1.1 x 1.1等;-表示 0.9、--mean0.9 x 0.9等)
提示之間的混合
您可以使用該函數在提示中混合概念.blend()。
例如:("blue sphere", "red cube").blend(0.25,0.75)
這將告訴采樣器將 25% 的藍色球體概念與 75% 的紅色立方體概念混合。混合權重可以使用整數和浮點數的任意組合。
轉義括號 () 和語音標記 ""
如果您使用的提示在其語法中包含括號()或語音標記"",您將需要使用反斜杠“轉義”它們,以便(my_keyword) 成為\(my_keyword\). 否則,提示解析器將嘗試將括號解釋為提示語法的一部分,并且會感到困惑。
哇!又賺了一天人民幣

浙公網安備 33010602011771號