Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| b2bbc01b92 | |||
| 884f1dc1af | |||
| 2cb3c2da3f | |||
| 11971e81c8 |
-117
@@ -1,120 +1,3 @@
|
|||||||
## 1.10.1
|
|
||||||
|
|
||||||
### Bug Fixes:
|
|
||||||
* fix image upscale on cpu ([#16275](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16275))
|
|
||||||
|
|
||||||
|
|
||||||
## 1.10.0
|
|
||||||
|
|
||||||
### Features:
|
|
||||||
* A lot of performance improvements (see below in Performance section)
|
|
||||||
* Stable Diffusion 3 support ([#16030](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16030), [#16164](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16164), [#16212](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16212))
|
|
||||||
* Recommended Euler sampler; DDIM and other timestamp samplers currently not supported
|
|
||||||
* T5 text model is disabled by default, enable it in settings
|
|
||||||
* New schedulers:
|
|
||||||
* Align Your Steps ([#15751](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15751))
|
|
||||||
* KL Optimal ([#15608](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15608))
|
|
||||||
* Normal ([#16149](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16149))
|
|
||||||
* DDIM ([#16149](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16149))
|
|
||||||
* Simple ([#16142](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16142))
|
|
||||||
* Beta ([#16235](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16235))
|
|
||||||
* New sampler: DDIM CFG++ ([#16035](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16035))
|
|
||||||
|
|
||||||
### Minor:
|
|
||||||
* Option to skip CFG on early steps ([#15607](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15607))
|
|
||||||
* Add --models-dir option ([#15742](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15742))
|
|
||||||
* Allow mobile users to open context menu by using two fingers press ([#15682](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15682))
|
|
||||||
* Infotext: add Lora name as TI hashes for bundled Textual Inversion ([#15679](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15679))
|
|
||||||
* Check model's hash after downloading it to prevent corruped downloads ([#15602](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15602))
|
|
||||||
* More extension tag filtering options ([#15627](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15627))
|
|
||||||
* When saving AVIF, use JPEG's quality setting ([#15610](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15610))
|
|
||||||
* Add filename pattern: `[basename]` ([#15978](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15978))
|
|
||||||
* Add option to enable clip skip for clip L on SDXL ([#15992](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15992))
|
|
||||||
* Option to prevent screen sleep during generation ([#16001](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16001))
|
|
||||||
* ToggleLivePriview button in image viewer ([#16065](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16065))
|
|
||||||
* Remove ui flashing on reloading and fast scrollong ([#16153](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16153))
|
|
||||||
* option to disable save button log.csv ([#16242](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16242))
|
|
||||||
|
|
||||||
### Extensions and API:
|
|
||||||
* Add process_before_every_sampling hook ([#15984](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15984))
|
|
||||||
* Return HTTP 400 instead of 404 on invalid sampler error ([#16140](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16140))
|
|
||||||
|
|
||||||
### Performance:
|
|
||||||
* [Performance 1/6] use_checkpoint = False ([#15803](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15803))
|
|
||||||
* [Performance 2/6] Replace einops.rearrange with torch native ops ([#15804](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15804))
|
|
||||||
* [Performance 4/6] Precompute is_sdxl_inpaint flag ([#15806](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15806))
|
|
||||||
* [Performance 5/6] Prevent unnecessary extra networks bias backup ([#15816](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15816))
|
|
||||||
* [Performance 6/6] Add --precision half option to avoid casting during inference ([#15820](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15820))
|
|
||||||
* [Performance] LDM optimization patches ([#15824](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15824))
|
|
||||||
* [Performance] Keep sigmas on CPU ([#15823](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15823))
|
|
||||||
* Check for nans in unet only once, after all steps have been completed
|
|
||||||
* Added pption to run torch profiler for image generation
|
|
||||||
|
|
||||||
### Bug Fixes:
|
|
||||||
* Fix for grids without comprehensive infotexts ([#15958](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15958))
|
|
||||||
* feat: lora partial update precede full update ([#15943](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15943))
|
|
||||||
* Fix bug where file extension had an extra '.' under some circumstances ([#15893](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15893))
|
|
||||||
* Fix corrupt model initial load loop ([#15600](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15600))
|
|
||||||
* Allow old sampler names in API ([#15656](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15656))
|
|
||||||
* more old sampler scheduler compatibility ([#15681](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15681))
|
|
||||||
* Fix Hypertile xyz ([#15831](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15831))
|
|
||||||
* XYZ CSV skipinitialspace ([#15832](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15832))
|
|
||||||
* fix soft inpainting on mps and xpu, torch_utils.float64 ([#15815](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15815))
|
|
||||||
* fix extention update when not on main branch ([#15797](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15797))
|
|
||||||
* update pickle safe filenames
|
|
||||||
* use relative path for webui-assets css ([#15757](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15757))
|
|
||||||
* When creating a virtual environment, upgrade pip in webui.bat/webui.sh ([#15750](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15750))
|
|
||||||
* Fix AttributeError ([#15738](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15738))
|
|
||||||
* use script_path for webui root in launch_utils ([#15705](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15705))
|
|
||||||
* fix extra batch mode P Transparency ([#15664](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15664))
|
|
||||||
* use gradio theme colors in css ([#15680](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15680))
|
|
||||||
* Fix dragging text within prompt input ([#15657](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15657))
|
|
||||||
* Add correct mimetype for .mjs files ([#15654](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15654))
|
|
||||||
* QOL Items - handle metadata issues more cleanly for SD models, Loras and embeddings ([#15632](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15632))
|
|
||||||
* replace wsl-open with wslpath and explorer.exe ([#15968](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15968))
|
|
||||||
* Fix SDXL Inpaint ([#15976](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15976))
|
|
||||||
* multi size grid ([#15988](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15988))
|
|
||||||
* fix Replace preview ([#16118](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16118))
|
|
||||||
* Possible fix of wrong scale in weight decomposition ([#16151](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16151))
|
|
||||||
* Ensure use of python from venv on Mac and Linux ([#16116](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16116))
|
|
||||||
* Prioritize python3.10 over python3 if both are available on Linux and Mac (with fallback) ([#16092](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16092))
|
|
||||||
* stoping generation extras ([#16085](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16085))
|
|
||||||
* Fix SD2 loading ([#16078](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16078), [#16079](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16079))
|
|
||||||
* fix infotext Lora hashes for hires fix different lora ([#16062](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16062))
|
|
||||||
* Fix sampler scheduler autocorrection warning ([#16054](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16054))
|
|
||||||
* fix ui flashing on reloading and fast scrollong ([#16153](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16153))
|
|
||||||
* fix upscale logic ([#16239](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16239))
|
|
||||||
* [bug] do not break progressbar on non-job actions (add wrap_gradio_call_no_job) ([#16202](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16202))
|
|
||||||
* fix OSError: cannot write mode P as JPEG ([#16194](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16194))
|
|
||||||
|
|
||||||
### Other:
|
|
||||||
* fix changelog #15883 -> #15882 ([#15907](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15907))
|
|
||||||
* ReloadUI backgroundColor --background-fill-primary ([#15864](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15864))
|
|
||||||
* Use different torch versions for Intel and ARM Macs ([#15851](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15851))
|
|
||||||
* XYZ override rework ([#15836](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15836))
|
|
||||||
* scroll extensions table on overflow ([#15830](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15830))
|
|
||||||
* img2img batch upload method ([#15817](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15817))
|
|
||||||
* chore: sync v1.8.0 packages according to changelog ([#15783](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15783))
|
|
||||||
* Add AVIF MIME type support to mimetype definitions ([#15739](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15739))
|
|
||||||
* Update imageviewer.js ([#15730](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15730))
|
|
||||||
* no-referrer ([#15641](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15641))
|
|
||||||
* .gitignore trace.json ([#15980](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/15980))
|
|
||||||
* Bump spandrel to 0.3.4 ([#16144](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16144))
|
|
||||||
* Defunct --max-batch-count ([#16119](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16119))
|
|
||||||
* docs: update bug_report.yml ([#16102](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16102))
|
|
||||||
* Maintaining Project Compatibility for Python 3.9 Users Without Upgrade Requirements. ([#16088](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16088), [#16169](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16169), [#16192](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16192))
|
|
||||||
* Update torch for ARM Macs to 2.3.1 ([#16059](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16059))
|
|
||||||
* remove deprecated setting dont_fix_second_order_samplers_schedule ([#16061](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16061))
|
|
||||||
* chore: fix typos ([#16060](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16060))
|
|
||||||
* shlex.join launch args in console log ([#16170](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16170))
|
|
||||||
* activate venv .bat ([#16231](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16231))
|
|
||||||
* add ids to the resize tabs in img2img ([#16218](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16218))
|
|
||||||
* update installation guide linux ([#16178](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16178))
|
|
||||||
* Robust sysinfo ([#16173](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16173))
|
|
||||||
* do not send image size on paste inpaint ([#16180](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16180))
|
|
||||||
* Fix noisy DS_Store files for MacOS ([#16166](https://github.com/AUTOMATIC1111/stable-diffusion-webui/pull/16166))
|
|
||||||
|
|
||||||
|
|
||||||
## 1.9.4
|
## 1.9.4
|
||||||
|
|
||||||
### Bug Fixes:
|
### Bug Fixes:
|
||||||
|
|||||||
@@ -77,6 +77,33 @@ def expand_crop_region(crop_region, processing_width, processing_height, image_w
|
|||||||
return x1, y1, x2, y2
|
return x1, y1, x2, y2
|
||||||
|
|
||||||
|
|
||||||
|
def expand_too_small_crop_region(crop_region, processing_width, processing_height, image_width, image_height):
|
||||||
|
"""expands a crop_region to not have dimensions smaller than processing_dimensions"""
|
||||||
|
|
||||||
|
def _expand_segment(c1, c2, desirable_length, maximal_coordinate):
|
||||||
|
"""expands the segment given by c1 c2 to the desired_dimension but not exceeding the boundaries of the maximal_coordinate"""
|
||||||
|
if (diff := desirable_length + c1 - c2) > 0:
|
||||||
|
# if the region is smaller than desirable_length, extend both sides equally
|
||||||
|
diff_l = diff // 2
|
||||||
|
c1 -= diff_l
|
||||||
|
c2 += diff - diff_l
|
||||||
|
if c1 < 0: # shift the region to the right by c1
|
||||||
|
c2 = min(c2 - c1, maximal_coordinate) # ensure c2 is within maximal_coordinate
|
||||||
|
c1 = 0
|
||||||
|
elif c2 >= maximal_coordinate: # shift the region to the left by (c2 - maximal_coordinate)
|
||||||
|
c1 = max(c1 - c2 + maximal_coordinate, 0) # ensure c1 is not below 0
|
||||||
|
c2 = maximal_coordinate
|
||||||
|
return c1, c2
|
||||||
|
|
||||||
|
x1, y1, x2, y2 = crop_region
|
||||||
|
x1, x2 = _expand_segment(x1, x2, processing_width, image_width)
|
||||||
|
y1, y2 = _expand_segment(y1, y2, processing_height, image_height)
|
||||||
|
new_crop_region = x1, y1, x2, y2
|
||||||
|
if new_crop_region != crop_region:
|
||||||
|
print("Crop region was smaller then resolution and has been corrected")
|
||||||
|
return new_crop_region
|
||||||
|
|
||||||
|
|
||||||
def fill(image, mask):
|
def fill(image, mask):
|
||||||
"""fills masked regions with colors from image using blur. Not extremely effective."""
|
"""fills masked regions with colors from image using blur. Not extremely effective."""
|
||||||
|
|
||||||
|
|||||||
@@ -1639,6 +1639,8 @@ class StableDiffusionProcessingImg2Img(StableDiffusionProcessing):
|
|||||||
crop_region = masking.get_crop_region_v2(mask, self.inpaint_full_res_padding)
|
crop_region = masking.get_crop_region_v2(mask, self.inpaint_full_res_padding)
|
||||||
if crop_region:
|
if crop_region:
|
||||||
crop_region = masking.expand_crop_region(crop_region, self.width, self.height, mask.width, mask.height)
|
crop_region = masking.expand_crop_region(crop_region, self.width, self.height, mask.width, mask.height)
|
||||||
|
if shared.opts.forbid_too_small_crop_region:
|
||||||
|
crop_region = masking.expand_too_small_crop_region(crop_region, self.width, self.height, mask.width, mask.height)
|
||||||
x1, y1, x2, y2 = crop_region
|
x1, y1, x2, y2 = crop_region
|
||||||
mask = mask.crop(crop_region)
|
mask = mask.crop(crop_region)
|
||||||
image_mask = images.resize_image(2, mask, self.width, self.height)
|
image_mask = images.resize_image(2, mask, self.width, self.height)
|
||||||
|
|||||||
@@ -227,6 +227,7 @@ options_templates.update(options_section(('img2img', "img2img", "sd"), {
|
|||||||
"return_mask_composite": OptionInfo(False, "For inpainting, include masked composite in results for web"),
|
"return_mask_composite": OptionInfo(False, "For inpainting, include masked composite in results for web"),
|
||||||
"img2img_batch_show_results_limit": OptionInfo(32, "Show the first N batch img2img results in UI", gr.Slider, {"minimum": -1, "maximum": 1000, "step": 1}).info('0: disable, -1: show all images. Too many images can cause lag'),
|
"img2img_batch_show_results_limit": OptionInfo(32, "Show the first N batch img2img results in UI", gr.Slider, {"minimum": -1, "maximum": 1000, "step": 1}).info('0: disable, -1: show all images. Too many images can cause lag'),
|
||||||
"overlay_inpaint": OptionInfo(True, "Overlay original for inpaint").info("when inpainting, overlay the original image over the areas that weren't inpainted."),
|
"overlay_inpaint": OptionInfo(True, "Overlay original for inpaint").info("when inpainting, overlay the original image over the areas that weren't inpainted."),
|
||||||
|
"forbid_too_small_crop_region": OptionInfo(False, "Forbid too small crop region").info("Correct inpaint padding for only masked to avoid crop region sides less then processing resolution"),
|
||||||
}))
|
}))
|
||||||
|
|
||||||
options_templates.update(options_section(('optimizations', "Optimizations", "sd"), {
|
options_templates.update(options_section(('optimizations', "Optimizations", "sd"), {
|
||||||
|
|||||||
@@ -41,7 +41,7 @@ def upscale_pil_patch(model, img: Image.Image) -> Image.Image:
|
|||||||
"""
|
"""
|
||||||
param = torch_utils.get_param(model)
|
param = torch_utils.get_param(model)
|
||||||
|
|
||||||
with torch.inference_mode():
|
with torch.no_grad():
|
||||||
tensor = pil_image_to_torch_bgr(img).unsqueeze(0) # add batch dimension
|
tensor = pil_image_to_torch_bgr(img).unsqueeze(0) # add batch dimension
|
||||||
tensor = tensor.to(device=param.device, dtype=param.dtype)
|
tensor = tensor.to(device=param.device, dtype=param.dtype)
|
||||||
with devices.without_autocast():
|
with devices.without_autocast():
|
||||||
|
|||||||
@@ -11,30 +11,25 @@ from modules.shared import state
|
|||||||
|
|
||||||
|
|
||||||
def process_model_tag(tag):
|
def process_model_tag(tag):
|
||||||
"""\"mode-name\""""
|
|
||||||
info = sd_models.get_closet_checkpoint_match(tag)
|
info = sd_models.get_closet_checkpoint_match(tag)
|
||||||
assert info is not None, f'Unknown checkpoint: {tag}'
|
assert info is not None, f'Unknown checkpoint: {tag}'
|
||||||
return info.name
|
return info.name
|
||||||
|
|
||||||
|
|
||||||
def process_string_tag(tag):
|
def process_string_tag(tag):
|
||||||
"""\"str\""""
|
|
||||||
return tag
|
return tag
|
||||||
|
|
||||||
|
|
||||||
def process_int_tag(tag):
|
def process_int_tag(tag):
|
||||||
"""int-number"""
|
|
||||||
return int(tag)
|
return int(tag)
|
||||||
|
|
||||||
|
|
||||||
def process_float_tag(tag):
|
def process_float_tag(tag):
|
||||||
"""float-number"""
|
|
||||||
return float(tag)
|
return float(tag)
|
||||||
|
|
||||||
|
|
||||||
def process_boolean_tag(tag):
|
def process_boolean_tag(tag):
|
||||||
"""true|false"""
|
return True if (tag == "true") else False
|
||||||
return True if (tag.lower() == "true") else False
|
|
||||||
|
|
||||||
|
|
||||||
prompt_tags = {
|
prompt_tags = {
|
||||||
@@ -65,27 +60,6 @@ prompt_tags = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
def doc_md():
|
|
||||||
md = '<details><summary>Usage Syntax</summary><p>\n\n'
|
|
||||||
for key, func in prompt_tags.items():
|
|
||||||
md += f'`--{key}` `{func.__doc__}`\n'
|
|
||||||
|
|
||||||
md += '''
|
|
||||||
<details><summary>Example</summary><p>
|
|
||||||
|
|
||||||
```shell
|
|
||||||
--prompt "photo of sunset"
|
|
||||||
--prompt "photo of sunset" --negative_prompt "orange, pink, red, sea, water, lake" --width 1024 --height 768 --sampler_name "DPM++ 2M Karras" --steps 10 --batch_size 2 --cfg_scale 3 --seed 9
|
|
||||||
--prompt "photo of winter mountains" --steps 7 --sampler_name "DDIM"
|
|
||||||
--prompt "photo of winter mountains" --width 1024
|
|
||||||
```
|
|
||||||
</p></details>
|
|
||||||
'''
|
|
||||||
|
|
||||||
md += '</p></details>'
|
|
||||||
return md
|
|
||||||
|
|
||||||
|
|
||||||
def cmdargs(line):
|
def cmdargs(line):
|
||||||
args = shlex.split(line)
|
args = shlex.split(line)
|
||||||
pos = 0
|
pos = 0
|
||||||
@@ -110,6 +84,7 @@ def cmdargs(line):
|
|||||||
res[tag] = prompt
|
res[tag] = prompt
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
|
||||||
func = prompt_tags.get(tag, None)
|
func = prompt_tags.get(tag, None)
|
||||||
assert func, f'unknown commandline option: {arg}'
|
assert func, f'unknown commandline option: {arg}'
|
||||||
|
|
||||||
@@ -150,9 +125,6 @@ class Script(scripts.Script):
|
|||||||
# We don't shrink back to 1, because that causes the control to ignore [enter], and it may
|
# We don't shrink back to 1, because that causes the control to ignore [enter], and it may
|
||||||
# be unclear to the user that shift-enter is needed.
|
# be unclear to the user that shift-enter is needed.
|
||||||
prompt_txt.change(lambda tb: gr.update(lines=7) if ("\n" in tb) else gr.update(lines=2), inputs=[prompt_txt], outputs=[prompt_txt], show_progress=False)
|
prompt_txt.change(lambda tb: gr.update(lines=7) if ("\n" in tb) else gr.update(lines=2), inputs=[prompt_txt], outputs=[prompt_txt], show_progress=False)
|
||||||
|
|
||||||
gr.Markdown(doc_md())
|
|
||||||
|
|
||||||
return [checkbox_iterate, checkbox_iterate_batch, prompt_position, prompt_txt]
|
return [checkbox_iterate, checkbox_iterate_batch, prompt_position, prompt_txt]
|
||||||
|
|
||||||
def run(self, p, checkbox_iterate, checkbox_iterate_batch, prompt_position, prompt_txt: str):
|
def run(self, p, checkbox_iterate, checkbox_iterate_batch, prompt_position, prompt_txt: str):
|
||||||
|
|||||||
Reference in New Issue
Block a user