fix yolo model refresh

Signed-off-by: Vladimir Mandic <mandic00@live.com>
This commit is contained in:
Vladimir Mandic
2025-07-29 06:04:14 -04:00
parent 1b7e9d84bb
commit 7dcc5b67f6
2 changed files with 7 additions and 6 deletions
+4 -3
View File
@@ -1,8 +1,8 @@
# Change Log for SD.Next
## Update for 2025-07-28
## Update for 2025-07-29
### Highlights for 2025-07-28
### Highlights for 2025-07-29
Feature highlights include:
- **ModernUI** has quite some redesign which should make it more user friendly and easier to navigate plus several new UI themes!
@@ -32,7 +32,7 @@ For details, see [ChangeLog](https://github.com/vladmandic/automatic/blob/master
[ReadMe](https://github.com/vladmandic/automatic/blob/master/README.md) | [ChangeLog](https://github.com/vladmandic/automatic/blob/master/CHANGELOG.md) | [Docs](https://vladmandic.github.io/sdnext-docs/) | [WiKi](https://github.com/vladmandic/automatic/wiki) | [Discord](https://discord.com/invite/sd-next-federal-batch-inspectors-1101998836328697867)
### Details for 2025-07-28
### Details for 2025-07-29
- **License**
- SD.Next [license](https://github.com/vladmandic/sdnext/blob/dev/LICENSE.txt) switched from **aGPL-v3.0** to **Apache-v2.0**
@@ -169,6 +169,7 @@ For details, see [ChangeLog](https://github.com/vladmandic/automatic/blob/master
- fix prompt encoding if prompts within batch have different segment counts
- fix detailer min/max size
- fix loopback script
- fix yolo refresh models
- cleanup control infotext
- allow upscaling with models that have implicit VAE processing
- framepack improve offloading
+3 -3
View File
@@ -69,7 +69,7 @@ class YoloRestorer(Detailer):
if name not in files:
self.list[name] = os.path.join(shared.opts.yolo_dir, f)
shared.log.info(f'Available Detailer: path="{shared.opts.yolo_dir}" items={len(list(self.list))} downloaded={downloaded}')
return self.list
return list(self.list)
def dependencies(self):
import installer
@@ -412,9 +412,9 @@ class YoloRestorer(Detailer):
enabled = gr.Checkbox(label="Enable detailer pass", elem_id=f"{tab}_detailer_enabled", value=False)
merge = gr.Checkbox(label="Merge detailers", elem_id=f"{tab}_detailer_merge", value=shared.opts.detailer_merge, visible=True)
with gr.Row():
detailers = gr.Dropdown(label="Detailer models", elem_id=f"{tab}_detailers", choices=self.list, value=shared.opts.detailer_models, multiselect=True, visible=True)
detailers = gr.Dropdown(label="Detailer models", elem_id=f"{tab}_detailers", choices=list(self.list), value=shared.opts.detailer_models, multiselect=True, visible=True)
detailers_text = gr.Textbox(label="Detailer list", elem_id=f"{tab}_detailers_text", placeholder="Comma separated list of detailer models", lines=2, visible=False, interactive=True)
refresh_btn = ui_common.create_refresh_button(detailers, self.enumerate, {}, elem_id=f"{tab}_detailers_refresh")
refresh_btn = ui_common.create_refresh_button(detailers, self.enumerate, lambda: {"choices": self.enumerate()}, 'yolo_refresh_models')
ui_mode = ui_components.ToolButton(value=ui_symbols.view)
ui_mode.click(fn=self.change_mode, inputs=[detailers, detailers_text], outputs=[detailers, detailers_text, refresh_btn])
with gr.Row():