diff options
author | AUTOMATIC <16777216c@gmail.com> | 2022-10-02 16:40:51 +0000 |
---|---|---|
committer | AUTOMATIC <16777216c@gmail.com> | 2022-10-02 16:40:51 +0000 |
commit | 88ec0cf5571883d84abd09196652b3679e359f2e (patch) | |
tree | 030b33b3060c750ea5e8212049c293388f2fc3b3 /modules/ui.py | |
parent | 53a3dc601fb734ce433505b1ca68770919106bad (diff) | |
download | stable-diffusion-webui-gfx803-88ec0cf5571883d84abd09196652b3679e359f2e.tar.gz stable-diffusion-webui-gfx803-88ec0cf5571883d84abd09196652b3679e359f2e.tar.bz2 stable-diffusion-webui-gfx803-88ec0cf5571883d84abd09196652b3679e359f2e.zip |
fix for incorrect embedding token length calculation (will break seeds that use embeddings, you're welcome!)
add option to input initialization text for embeddings
Diffstat (limited to 'modules/ui.py')
-rw-r--r-- | modules/ui.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/modules/ui.py b/modules/ui.py index 3b81a4f7..eca50df0 100644 --- a/modules/ui.py +++ b/modules/ui.py @@ -954,6 +954,7 @@ def create_ui(wrap_gradio_gpu_call): gr.HTML(value="<p style='margin-bottom: 0.7em'>Create a new embedding</p>")
new_embedding_name = gr.Textbox(label="Name")
+ initialization_text = gr.Textbox(label="Initialization text", value="*")
nvpt = gr.Slider(label="Number of vectors per token", minimum=1, maximum=75, step=1, value=1)
with gr.Row():
@@ -997,6 +998,7 @@ def create_ui(wrap_gradio_gpu_call): fn=modules.textual_inversion.ui.create_embedding,
inputs=[
new_embedding_name,
+ initialization_text,
nvpt,
],
outputs=[
|