auto-git:
[change] generate_equirect.py
This commit is contained in:
@@ -720,8 +720,34 @@ def main():
|
||||
choices=['euler', 'euler_a', 'heun', 'ddim', 'dpmsolver', 'dpmsolver-sde'],
|
||||
help='Sampler/scheduler override; default uses the pipeline scheduler (Euler for SDXL base)'
|
||||
)
|
||||
parser.add_argument('--postprocess-input', help=argparse.SUPPRESS)
|
||||
parser.add_argument('--postprocess-output', help=argparse.SUPPRESS)
|
||||
parser.add_argument('--postprocess-tempdir', help=argparse.SUPPRESS)
|
||||
args = parser.parse_args()
|
||||
|
||||
if args.postprocess_input:
|
||||
if not args.postprocess_output or not args.postprocess_tempdir:
|
||||
parser.error("--postprocess-input requires --postprocess-output and --postprocess-tempdir")
|
||||
try:
|
||||
result_path = postprocess_image(
|
||||
args.prompt,
|
||||
os.path.abspath(args.postprocess_input),
|
||||
os.path.abspath(args.postprocess_output),
|
||||
os.path.abspath(args.postprocess_tempdir),
|
||||
upscale=args.upscale,
|
||||
steps=args.steps,
|
||||
guidance=args.guidance,
|
||||
width=args.width,
|
||||
height=args.height,
|
||||
seam_inpaint=args.seam_inpaint,
|
||||
)
|
||||
print(result_path)
|
||||
shutil.rmtree(args.postprocess_tempdir, ignore_errors=True)
|
||||
return
|
||||
except Exception as e: # noqa: BLE001
|
||||
print(f"Generation failed: {e}")
|
||||
raise
|
||||
|
||||
base = sanitize_name(args.prompt)
|
||||
target = args.output or next_filename(args.output_dir, base, args.width, args.height)
|
||||
output_abs = os.path.abspath(target)
|
||||
|
||||
Reference in New Issue
Block a user