mirror of
https://github.com/vladmandic/automatic
synced 2026-09-19 01:04:32 +02:00
modernize typing
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
import os
|
||||
import tempfile
|
||||
from typing import List
|
||||
|
||||
from PIL import Image
|
||||
|
||||
@@ -9,7 +8,7 @@ from modules.shared import opts
|
||||
from modules.paths import resolve_output_path
|
||||
|
||||
|
||||
def run_postprocessing(extras_mode, image, image_folder: List[tempfile.NamedTemporaryFile], input_dir, output_dir, show_extras_results, *args, save_output: bool = True):
|
||||
def run_postprocessing(extras_mode, image, image_folder: list[tempfile.NamedTemporaryFile], input_dir, output_dir, show_extras_results, *args, save_output: bool = True):
|
||||
devices.torch_gc()
|
||||
shared.state.begin('Extras')
|
||||
image_data = []
|
||||
@@ -61,7 +60,7 @@ def run_postprocessing(extras_mode, image, image_folder: List[tempfile.NamedTemp
|
||||
else:
|
||||
outpath = resolve_output_path(opts.outdir_samples, opts.outdir_extras_samples)
|
||||
processed_images = []
|
||||
for image, name, ext in zip(image_data, image_names, image_ext): # pylint: disable=redefined-argument-from-local
|
||||
for image, name, ext in zip(image_data, image_names, image_ext, strict=False): # pylint: disable=redefined-argument-from-local
|
||||
shared.log.debug(f'Process: image={image} {args}')
|
||||
info = ''
|
||||
if shared.state.interrupted:
|
||||
|
||||
Reference in New Issue
Block a user