mirror of
https://github.com/vladmandic/automatic
synced 2026-09-19 01:04:32 +02:00
lint fixes
This commit is contained in:
+1
-2
@@ -579,7 +579,6 @@ save_thread.start()
|
||||
|
||||
|
||||
def save_image(image, path, basename='', seed=None, prompt=None, extension=shared.opts.samples_format, info=None, short_filename=False, no_prompt=False, grid=False, pnginfo_section_name='parameters', p=None, existing_info=None, forced_filename=None, suffix='', save_to_dirs=None): # pylint: disable=unused-argument
|
||||
import sys
|
||||
if image is None:
|
||||
shared.log.warning('Image is none')
|
||||
return None, None
|
||||
@@ -683,7 +682,7 @@ def save_video(p, images, filename = None, video_type: str = 'none', duration: f
|
||||
filename = os.path.join(shared.opts.outdir_video, filename)
|
||||
filename = namegen.sequence(filename, shared.opts.outdir_video, '')
|
||||
else:
|
||||
if not os.pathsep in filename:
|
||||
if os.pathsep not in filename:
|
||||
filename = os.path.join(shared.opts.outdir_video, filename)
|
||||
if not filename.lower().endswith(video_type.lower()):
|
||||
filename += f'.{video_type.lower()}'
|
||||
|
||||
+1
-1
@@ -280,7 +280,7 @@ options_templates.update(options_section(('cuda', "Compute Settings"), {
|
||||
"cuda_dtype": OptionInfo("FP32" if sys.platform == "darwin" or cmd_opts.use_openvino else "BF16" if devices.backend == "ipex" else "FP16", "Device precision type", gr.Radio, {"choices": ["FP32", "FP16", "BF16"]}),
|
||||
"no_half": OptionInfo(False if not cmd_opts.use_openvino else True, "Use full precision for model (--no-half)", None, None, None),
|
||||
"no_half_vae": OptionInfo(False if not cmd_opts.use_openvino else True, "Use full precision for VAE (--no-half-vae)"),
|
||||
"upcast_sampling": OptionInfo(False if not sys.platform == "darwin" else True, "Enable upcast sampling"),
|
||||
"upcast_sampling": OptionInfo(False if sys.platform != "darwin" else True, "Enable upcast sampling"),
|
||||
"upcast_attn": OptionInfo(False, "Enable upcast cross attention layer"),
|
||||
"cuda_cast_unet": OptionInfo(False, "Use fixed UNet precision"),
|
||||
"disable_nan_check": OptionInfo(True, "Disable NaN check in produced images/latent spaces", gr.Checkbox, {"visible": False}),
|
||||
|
||||
Reference in New Issue
Block a user