From 50d1e2bb795fc6cd9fe993fb570a6e4380155564 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Sat, 21 Dec 2024 19:29:39 +0000 Subject: [PATCH] chore(format): run black on main --- tabs/extra/sections/processing.py | 39 ++++++++++++++++--------------- tabs/inference/inference.py | 2 +- 2 files changed, 21 insertions(+), 20 deletions(-) diff --git a/tabs/extra/sections/processing.py b/tabs/extra/sections/processing.py index 631c0a01..1d12640e 100644 --- a/tabs/extra/sections/processing.py +++ b/tabs/extra/sections/processing.py @@ -10,24 +10,25 @@ i18n = I18nAuto() + def processing_tab(): - model_view_model_path = gr.Textbox( - label=i18n("Path to Model"), - info=i18n("Introduce the model pth path"), - value="", - interactive=True, - placeholder=i18n("Enter path to model"), - ) + model_view_model_path = gr.Textbox( + label=i18n("Path to Model"), + info=i18n("Introduce the model pth path"), + value="", + interactive=True, + placeholder=i18n("Enter path to model"), + ) - model_view_output_info = gr.Textbox( - label=i18n("Output Information"), - info=i18n("The output information will be displayed here."), - value="", - max_lines=11, - ) - model_view_button = gr.Button(i18n("View")) - model_view_button.click( - fn=run_model_information_script, - inputs=[model_view_model_path], - outputs=[model_view_output_info], - ) + model_view_output_info = gr.Textbox( + label=i18n("Output Information"), + info=i18n("The output information will be displayed here."), + value="", + max_lines=11, + ) + model_view_button = gr.Button(i18n("View")) + model_view_button.click( + fn=run_model_information_script, + inputs=[model_view_model_path], + outputs=[model_view_output_info], + ) diff --git a/tabs/inference/inference.py b/tabs/inference/inference.py index 2382c9ab..f6fac000 100644 --- a/tabs/inference/inference.py +++ b/tabs/inference/inference.py @@ -243,7 +243,7 @@ def get_indexes(): def extract_model_and_epoch(path): base_name = os.path.basename(path) - match = re.match(r'(.+?)_(\d+)e_', base_name) + match = re.match(r"(.+?)_(\d+)e_", base_name) if match: model, epoch = match.groups() return model, int(epoch)