From ef28e3ad7fbec03c6c3451c25122081baf5df9ed Mon Sep 17 00:00:00 2001 From: Somdev Sangwan Date: Wed, 31 May 2023 14:43:21 +0530 Subject: [PATCH] fix target_path undefined --- run.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/run.py b/run.py index 6449de9..e169f39 100755 --- a/run.py +++ b/run.py @@ -179,7 +179,8 @@ def start(): print("\n[WARNING] Please select a video/image to swap face in.") return if not args['output_file']: - args['output_file'] = rreplace(args['target_path'], "/", "/swapped-", 1) if "/" in target_path else "swapped-" + target_path + target_path = args['target_path'] + args['output_file'] = rreplace(target_path, "/", "/swapped-", 1) if "/" in target_path else "swapped-" + target_path global pool pool = mp.Pool(args['cores_count']) target_path = args['target_path']