diff --git a/facefusion/choices.py b/facefusion/choices.py index b492517a..c3b98aa4 100755 --- a/facefusion/choices.py +++ b/facefusion/choices.py @@ -45,7 +45,7 @@ face_mask_regions : List[FaceMaskRegion] = list(face_mask_region_set.keys()) voice_extractor_models : List[VoiceExtractorModel] = [ 'kim_vocal_1', 'kim_vocal_2', 'uvr_mdxnet' ] -workflows : List[WorkFlow] = [ 'auto', 'audio-to-image', 'image-to-image', 'image-to-video', 'image-to-video-as-sequence' ] +workflows : List[WorkFlow] = [ 'auto', 'audio-to-image:video', 'image-to-image', 'image-to-video', 'image-to-video:frame' ] audio_type_set : AudioTypeSet =\ { diff --git a/facefusion/core.py b/facefusion/core.py index a7115c4a..40c8214b 100755 --- a/facefusion/core.py +++ b/facefusion/core.py @@ -336,13 +336,13 @@ def conditional_process() -> ErrorCode: if not processor_module.pre_process('output'): return 2 - if state_manager.get_item('workflow') == 'audio-to-image': + if state_manager.get_item('workflow') == 'audio-to-image:video': return audio_to_image.process(start_time) if state_manager.get_item('workflow') == 'image-to-image': return image_to_image.process(start_time) if state_manager.get_item('workflow') == 'image-to-video': return image_to_video.process(start_time) - if state_manager.get_item('workflow') == 'image-to-video-as-sequence': + if state_manager.get_item('workflow') == 'image-to-video:frame': return image_to_video_as_sequence.process(start_time) return 0 @@ -352,9 +352,9 @@ def detect_workflow() -> WorkFlow: if has_video([ state_manager.get_item('target_path') ]): if get_file_extension(state_manager.get_item('output_path')): return 'image-to-video' - return 'image-to-video-as-sequence' + return 'image-to-video:frame' if has_audio(state_manager.get_item('source_paths')) and has_image([ state_manager.get_item('target_path') ]): - return 'audio-to-image' + return 'audio-to-image:video' return 'image-to-image' diff --git a/facefusion/processors/modules/age_modifier/core.py b/facefusion/processors/modules/age_modifier/core.py index 66968350..68d5d2fa 100755 --- a/facefusion/processors/modules/age_modifier/core.py +++ b/facefusion/processors/modules/age_modifier/core.py @@ -108,7 +108,7 @@ def pre_process(mode : ProcessMode) -> bool: if mode in [ 'output', 'preview' ] and not is_image(state_manager.get_item('target_path')) and not is_video(state_manager.get_item('target_path')): logger.error(translator.get('choose_image_or_video_target') + translator.get('exclamation_mark'), __name__) return False - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-image', 'image-to-video' ]: if mode == 'output' and not in_directory(state_manager.get_item('output_path')): logger.error(translator.get('specify_image_or_video_output') + translator.get('exclamation_mark'), __name__) return False diff --git a/facefusion/processors/modules/background_remover/core.py b/facefusion/processors/modules/background_remover/core.py index 318912f3..dda62415 100644 --- a/facefusion/processors/modules/background_remover/core.py +++ b/facefusion/processors/modules/background_remover/core.py @@ -441,7 +441,7 @@ def pre_process(mode : ProcessMode) -> bool: if mode in [ 'output', 'preview' ] and not is_image(state_manager.get_item('target_path')) and not is_video(state_manager.get_item('target_path')): logger.error(translator.get('choose_image_or_video_target') + translator.get('exclamation_mark'), __name__) return False - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-image', 'image-to-video' ]: if mode == 'output' and not in_directory(state_manager.get_item('output_path')): logger.error(translator.get('specify_image_or_video_output') + translator.get('exclamation_mark'), __name__) return False diff --git a/facefusion/processors/modules/deep_swapper/core.py b/facefusion/processors/modules/deep_swapper/core.py index e76e593f..577df558 100755 --- a/facefusion/processors/modules/deep_swapper/core.py +++ b/facefusion/processors/modules/deep_swapper/core.py @@ -299,7 +299,7 @@ def pre_process(mode : ProcessMode) -> bool: if mode in [ 'output', 'preview' ] and not is_image(state_manager.get_item('target_path')) and not is_video(state_manager.get_item('target_path')): logger.error(translator.get('choose_image_or_video_target') + translator.get('exclamation_mark'), __name__) return False - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-image', 'image-to-video' ]: if mode == 'output' and not in_directory(state_manager.get_item('output_path')): logger.error(translator.get('specify_image_or_video_output') + translator.get('exclamation_mark'), __name__) return False diff --git a/facefusion/processors/modules/expression_restorer/core.py b/facefusion/processors/modules/expression_restorer/core.py index f46ff5d7..6a60419b 100755 --- a/facefusion/processors/modules/expression_restorer/core.py +++ b/facefusion/processors/modules/expression_restorer/core.py @@ -125,7 +125,7 @@ def pre_process(mode : ProcessMode) -> bool: if mode in [ 'output', 'preview' ] and not is_image(state_manager.get_item('target_path')) and not is_video(state_manager.get_item('target_path')): logger.error(translator.get('choose_image_or_video_target') + translator.get('exclamation_mark'), __name__) return False - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-image', 'image-to-video' ]: if mode == 'output' and not in_directory(state_manager.get_item('output_path')): logger.error(translator.get('specify_image_or_video_output') + translator.get('exclamation_mark'), __name__) return False diff --git a/facefusion/processors/modules/face_debugger/core.py b/facefusion/processors/modules/face_debugger/core.py index aef6ad35..7ece4416 100755 --- a/facefusion/processors/modules/face_debugger/core.py +++ b/facefusion/processors/modules/face_debugger/core.py @@ -46,7 +46,7 @@ def pre_process(mode : ProcessMode) -> bool: if mode in [ 'output', 'preview' ] and not is_image(state_manager.get_item('target_path')) and not is_video(state_manager.get_item('target_path')): logger.error(translator.get('choose_image_or_video_target') + translator.get('exclamation_mark'), __name__) return False - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-image', 'image-to-video' ]: if mode == 'output' and not in_directory(state_manager.get_item('output_path')): logger.error(translator.get('specify_image_or_video_output') + translator.get('exclamation_mark'), __name__) return False diff --git a/facefusion/processors/modules/face_editor/core.py b/facefusion/processors/modules/face_editor/core.py index 30504c18..41380bdb 100755 --- a/facefusion/processors/modules/face_editor/core.py +++ b/facefusion/processors/modules/face_editor/core.py @@ -176,7 +176,7 @@ def pre_process(mode : ProcessMode) -> bool: if mode in [ 'output', 'preview' ] and not is_image(state_manager.get_item('target_path')) and not is_video(state_manager.get_item('target_path')): logger.error(translator.get('choose_image_or_video_target') + translator.get('exclamation_mark'), __name__) return False - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-image', 'image-to-video' ]: if mode == 'output' and not in_directory(state_manager.get_item('output_path')): logger.error(translator.get('specify_image_or_video_output') + translator.get('exclamation_mark'), __name__) return False diff --git a/facefusion/processors/modules/face_enhancer/core.py b/facefusion/processors/modules/face_enhancer/core.py index 332be23c..0b5a64fa 100755 --- a/facefusion/processors/modules/face_enhancer/core.py +++ b/facefusion/processors/modules/face_enhancer/core.py @@ -315,7 +315,7 @@ def pre_process(mode : ProcessMode) -> bool: if mode in [ 'output', 'preview' ] and not is_image(state_manager.get_item('target_path')) and not is_video(state_manager.get_item('target_path')): logger.error(translator.get('choose_image_or_video_target') + translator.get('exclamation_mark'), __name__) return False - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-image', 'image-to-video' ]: if mode == 'output' and not in_directory(state_manager.get_item('output_path')): logger.error(translator.get('specify_image_or_video_output') + translator.get('exclamation_mark'), __name__) return False diff --git a/facefusion/processors/modules/face_swapper/core.py b/facefusion/processors/modules/face_swapper/core.py index 9730cf56..b48cf9b7 100755 --- a/facefusion/processors/modules/face_swapper/core.py +++ b/facefusion/processors/modules/face_swapper/core.py @@ -551,7 +551,7 @@ def pre_process(mode : ProcessMode) -> bool: logger.error(translator.get('choose_image_or_video_target') + translator.get('exclamation_mark'), __name__) return False - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-image', 'image-to-video' ]: if mode == 'output' and not in_directory(state_manager.get_item('output_path')): logger.error(translator.get('specify_image_or_video_output') + translator.get('exclamation_mark'), __name__) return False diff --git a/facefusion/processors/modules/frame_colorizer/core.py b/facefusion/processors/modules/frame_colorizer/core.py index fd789f1f..f81ad1d8 100644 --- a/facefusion/processors/modules/frame_colorizer/core.py +++ b/facefusion/processors/modules/frame_colorizer/core.py @@ -207,7 +207,7 @@ def pre_process(mode : ProcessMode) -> bool: if mode in [ 'output', 'preview' ] and not is_image(state_manager.get_item('target_path')) and not is_video(state_manager.get_item('target_path')): logger.error(translator.get('choose_image_or_video_target') + translator.get('exclamation_mark'), __name__) return False - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-image', 'image-to-video' ]: if mode == 'output' and not in_directory(state_manager.get_item('output_path')): logger.error(translator.get('specify_image_or_video_output') + translator.get('exclamation_mark'), __name__) return False diff --git a/facefusion/processors/modules/frame_enhancer/core.py b/facefusion/processors/modules/frame_enhancer/core.py index b48f3245..7b72e53b 100644 --- a/facefusion/processors/modules/frame_enhancer/core.py +++ b/facefusion/processors/modules/frame_enhancer/core.py @@ -594,7 +594,7 @@ def pre_process(mode : ProcessMode) -> bool: if mode in [ 'output', 'preview' ] and not is_image(state_manager.get_item('target_path')) and not is_video(state_manager.get_item('target_path')): logger.error(translator.get('choose_image_or_video_target') + translator.get('exclamation_mark'), __name__) return False - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-image', 'image-to-video' ]: if mode == 'output' and not in_directory(state_manager.get_item('output_path')): logger.error(translator.get('specify_image_or_video_output') + translator.get('exclamation_mark'), __name__) return False diff --git a/facefusion/types.py b/facefusion/types.py index fb2b8212..3a2aa58c 100755 --- a/facefusion/types.py +++ b/facefusion/types.py @@ -55,7 +55,7 @@ Language = Literal['en'] Locales : TypeAlias = Dict[Language, Dict[str, Any]] LocalePoolSet : TypeAlias = Dict[str, Locales] -WorkFlow = Literal['auto', 'audio-to-image', 'image-to-image', 'image-to-video', 'image-to-video-as-sequence'] +WorkFlow = Literal['auto', 'audio-to-image:video', 'image-to-image', 'image-to-video', 'image-to-video:frame'] VideoCaptureSet : TypeAlias = Dict[str, cv2.VideoCapture] VideoWriterSet : TypeAlias = Dict[str, cv2.VideoWriter] diff --git a/facefusion/workflows/core.py b/facefusion/workflows/core.py index 63db8984..109290f4 100644 --- a/facefusion/workflows/core.py +++ b/facefusion/workflows/core.py @@ -39,7 +39,7 @@ def analyse_image() -> ErrorCode: def conditional_get_source_audio_frame(frame_number : int) -> AudioFrame: - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-video' ]: source_audio_path = get_first(filter_audio_paths(state_manager.get_item('source_paths'))) output_video_fps = state_manager.get_item('output_video_fps') @@ -54,7 +54,7 @@ def conditional_get_source_audio_frame(frame_number : int) -> AudioFrame: def conditional_get_source_voice_frame(frame_number: int) -> AudioFrame: - if state_manager.get_item('workflow') in [ 'audio-to-image', 'image-to-video' ]: + if state_manager.get_item('workflow') in [ 'audio-to-image:video', 'image-to-video' ]: source_audio_path = get_first(filter_audio_paths(state_manager.get_item('source_paths'))) output_video_fps = state_manager.get_item('output_video_fps') @@ -69,7 +69,7 @@ def conditional_get_source_voice_frame(frame_number: int) -> AudioFrame: def conditional_get_reference_vision_frame() -> VisionFrame: - if state_manager.get_item('workflow') in [ 'image-to-video', 'image-to-video-as-sequence' ]: + if state_manager.get_item('workflow') in [ 'image-to-video', 'image-to-video:frame' ]: return read_static_video_frame(state_manager.get_item('target_path'), state_manager.get_item('reference_frame_number')) return read_static_image(state_manager.get_item('target_path')) diff --git a/tests/test_cli_age_modifier.py b/tests/test_cli_age_modifier.py index 50db990a..8a5bbea6 100644 --- a/tests/test_cli_age_modifier.py +++ b/tests/test_cli_age_modifier.py @@ -39,7 +39,7 @@ def test_modify_age_to_video() -> None: def test_modify_age_to_video_as_sequence() -> None: - commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video-as-sequence', '--jobs-path', get_test_jobs_directory(), '--processors', 'age_modifier', '--age-modifier-direction', '100', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-age-face-to-video-as-sequence'), '--trim-frame-end', '1' ] + commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video:frame', '--jobs-path', get_test_jobs_directory(), '--processors', 'age_modifier', '--age-modifier-direction', '100', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-age-face-to-video-as-sequence'), '--trim-frame-end', '1' ] assert subprocess.run(commands).returncode == 0 assert is_test_output_sequence(get_test_output_path('test-age-face-to-video-as-sequence')) is True diff --git a/tests/test_cli_background_remover.py b/tests/test_cli_background_remover.py index 19048adc..94d8428e 100644 --- a/tests/test_cli_background_remover.py +++ b/tests/test_cli_background_remover.py @@ -40,7 +40,7 @@ def test_remove_background_to_video() -> None: def test_remove_background_to_video_as_sequence() -> None: - commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video-as-sequence', '--jobs-path', get_test_jobs_directory(), '--processors', 'background_remover', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-remove-background-to-video-as-sequence'), '--trim-frame-end', '1' ] + commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video:frame', '--jobs-path', get_test_jobs_directory(), '--processors', 'background_remover', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-remove-background-to-video-as-sequence'), '--trim-frame-end', '1' ] assert subprocess.run(commands).returncode == 0 assert is_test_output_sequence(get_test_output_path('test-remove-background-to-video-as-sequence')) is True diff --git a/tests/test_cli_expression_restorer.py b/tests/test_cli_expression_restorer.py index 699f8402..e6372a68 100644 --- a/tests/test_cli_expression_restorer.py +++ b/tests/test_cli_expression_restorer.py @@ -39,7 +39,7 @@ def test_restore_expression_to_video() -> None: def test_restore_expression_to_video_as_sequence() -> None: - commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video-as-sequence', '--jobs-path', get_test_jobs_directory(), '--processors', 'expression_restorer', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-restore-expression-to-video-as-sequence'), '--trim-frame-end', '1' ] + commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video:frame', '--jobs-path', get_test_jobs_directory(), '--processors', 'expression_restorer', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-restore-expression-to-video-as-sequence'), '--trim-frame-end', '1' ] assert subprocess.run(commands).returncode == 0 assert is_test_output_sequence(get_test_output_path('test-restore-expression-to-video-as-sequence')) is True diff --git a/tests/test_cli_face_debugger.py b/tests/test_cli_face_debugger.py index 9fb687ca..c861ccda 100644 --- a/tests/test_cli_face_debugger.py +++ b/tests/test_cli_face_debugger.py @@ -40,7 +40,7 @@ def test_debug_face_to_video() -> None: def test_debug_face_to_video_as_sequence() -> None: - commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video-as-sequence', '--jobs-path', get_test_jobs_directory(), '--processors', 'face_debugger', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-debug-face-to-video-as-sequence'), '--trim-frame-end', '1' ] + commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video:frame', '--jobs-path', get_test_jobs_directory(), '--processors', 'face_debugger', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-debug-face-to-video-as-sequence'), '--trim-frame-end', '1' ] assert subprocess.run(commands).returncode == 0 assert is_test_output_sequence(get_test_output_path('test-debug-face-to-video-as-sequence')) is True diff --git a/tests/test_cli_face_editor.py b/tests/test_cli_face_editor.py index e0569fbb..918eb1b1 100644 --- a/tests/test_cli_face_editor.py +++ b/tests/test_cli_face_editor.py @@ -40,7 +40,7 @@ def test_edit_face_to_video() -> None: def test_edit_face_to_video_as_sequence() -> None: - commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video-as-sequence', '--jobs-path', get_test_jobs_directory(), '--processors', 'face_editor', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-edit-face-to-video-as-sequence'), '--trim-frame-end', '1' ] + commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video:frame', '--jobs-path', get_test_jobs_directory(), '--processors', 'face_editor', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-edit-face-to-video-as-sequence'), '--trim-frame-end', '1' ] assert subprocess.run(commands).returncode == 0 assert is_test_output_sequence(get_test_output_path('test-edit-face-to-video-as-sequence')) is True diff --git a/tests/test_cli_face_enhancer.py b/tests/test_cli_face_enhancer.py index a315ad69..652b929c 100644 --- a/tests/test_cli_face_enhancer.py +++ b/tests/test_cli_face_enhancer.py @@ -40,7 +40,7 @@ def test_enhance_face_to_video() -> None: def test_enhance_face_to_video_as_sequence() -> None: - commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video-as-sequence', '--jobs-path', get_test_jobs_directory(), '--processors', 'face_enhancer', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-enhance-face-to-video-as-sequence'), '--trim-frame-end', '1' ] + commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video:frame', '--jobs-path', get_test_jobs_directory(), '--processors', 'face_enhancer', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-enhance-face-to-video-as-sequence'), '--trim-frame-end', '1' ] assert subprocess.run(commands).returncode == 0 assert is_test_output_sequence(get_test_output_path('test-enhance-face-to-video-as-sequence')) is True diff --git a/tests/test_cli_face_swapper.py b/tests/test_cli_face_swapper.py index 1d77a82c..b5bfc742 100644 --- a/tests/test_cli_face_swapper.py +++ b/tests/test_cli_face_swapper.py @@ -40,7 +40,7 @@ def test_swap_face_to_video() -> None: def test_swap_face_to_video_as_sequence() -> None: - commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video-as-sequence', '--jobs-path', get_test_jobs_directory(), '--processors', 'face_swapper', '-s', get_test_example_file('source.jpg'), '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-swap-face-to-video-as-sequence'), '--trim-frame-end', '1' ] + commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video:frame', '--jobs-path', get_test_jobs_directory(), '--processors', 'face_swapper', '-s', get_test_example_file('source.jpg'), '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-swap-face-to-video-as-sequence'), '--trim-frame-end', '1' ] assert subprocess.run(commands).returncode == 0 assert is_test_output_sequence(get_test_output_path('test-swap-face-to-video-as-sequence')) is True diff --git a/tests/test_cli_frame_colorizer.py b/tests/test_cli_frame_colorizer.py index a3087b67..0a87a10e 100644 --- a/tests/test_cli_frame_colorizer.py +++ b/tests/test_cli_frame_colorizer.py @@ -41,7 +41,7 @@ def test_colorize_frame_to_video() -> None: def test_colorize_frame_to_video_as_sequence() -> None: - commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video-as-sequence', '--jobs-path', get_test_jobs_directory(), '--processors', 'frame_colorizer', '-t', get_test_example_file('target-240p-0sat.mp4'), '-o', get_test_output_path('test-colorize-frame-to-video-as-sequence'), '--trim-frame-end', '1' ] + commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video:frame', '--jobs-path', get_test_jobs_directory(), '--processors', 'frame_colorizer', '-t', get_test_example_file('target-240p-0sat.mp4'), '-o', get_test_output_path('test-colorize-frame-to-video-as-sequence'), '--trim-frame-end', '1' ] assert subprocess.run(commands).returncode == 0 assert is_test_output_sequence(get_test_output_path('test-colorize-frame-to-video-as-sequence')) is True diff --git a/tests/test_cli_frame_enhancer.py b/tests/test_cli_frame_enhancer.py index 27f03bbb..8a7b3ef6 100644 --- a/tests/test_cli_frame_enhancer.py +++ b/tests/test_cli_frame_enhancer.py @@ -40,7 +40,7 @@ def test_enhance_frame_to_video() -> None: def test_enhance_frame_to_video_as_sequence() -> None: - commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video-as-sequence', '--jobs-path', get_test_jobs_directory(), '--processors', 'frame_enhancer', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-enhance-frame-to-video-as-sequence'), '--trim-frame-end', '1' ] + commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video:frame', '--jobs-path', get_test_jobs_directory(), '--processors', 'frame_enhancer', '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test-enhance-frame-to-video-as-sequence'), '--trim-frame-end', '1' ] assert subprocess.run(commands).returncode == 0 assert is_test_output_sequence(get_test_output_path('test-enhance-frame-to-video-as-sequence')) is True diff --git a/tests/test_cli_lip_syncer.py b/tests/test_cli_lip_syncer.py index 47526a2a..b6ff196d 100644 --- a/tests/test_cli_lip_syncer.py +++ b/tests/test_cli_lip_syncer.py @@ -27,7 +27,7 @@ def before_each() -> None: def test_sync_lip_to_image() -> None: - commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'audio-to-image', '--jobs-path', get_test_jobs_directory(), '--processors', 'lip_syncer', '-s', get_test_example_file('source.mp3'), '-t', get_test_example_file('target-240p.jpg'), '-o', get_test_output_path('test_sync_lip_to_image.mp4') ] + commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'audio-to-image:video', '--jobs-path', get_test_jobs_directory(), '--processors', 'lip_syncer', '-s', get_test_example_file('source.mp3'), '-t', get_test_example_file('target-240p.jpg'), '-o', get_test_output_path('test_sync_lip_to_image.mp4') ] assert subprocess.run(commands).returncode == 0 assert is_test_output_file('test_sync_lip_to_image.mp4') is True @@ -41,7 +41,7 @@ def test_sync_lip_to_video() -> None: def test_sync_lip_to_video_as_sequence() -> None: - commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video-as-sequence', '--jobs-path', get_test_jobs_directory(), '--processors', 'lip_syncer', '-s', get_test_example_file('source.mp3'), '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test_sync_lip_to_video_as_sequence'), '--trim-frame-end', '1' ] + commands = [ sys.executable, 'facefusion.py', 'run', '--workflow', 'image-to-video:frame', '--jobs-path', get_test_jobs_directory(), '--processors', 'lip_syncer', '-s', get_test_example_file('source.mp3'), '-t', get_test_example_file('target-240p.mp4'), '-o', get_test_output_path('test_sync_lip_to_video_as_sequence'), '--trim-frame-end', '1' ] assert subprocess.run(commands).returncode == 0 assert is_test_output_sequence(get_test_output_path('test_sync_lip_to_video_as_sequence')) is True