mirror of
https://github.com/k4yt3x/video2x.git
synced 2026-02-22 06:44:46 +08:00
update waifu2x_ncnn_vulkan wrapper for directory as input
add workaround for the double file extension
This commit is contained in:
@@ -150,6 +150,14 @@ class Ffmpeg:
|
||||
# read FFmpeg input options
|
||||
execute.extend(self._read_configuration(phase='frames_to_video', section='input_options'))
|
||||
|
||||
# WORKAROUND FOR WAIFU2X-NCNN-VULKAN
|
||||
import re
|
||||
import shutil
|
||||
regex = re.compile(r'\.png\.png$')
|
||||
for raw_frame in os.listdir(upscaled_frames):
|
||||
shutil.move(os.path.join(upscaled_frames, raw_frame), os.path.join(upscaled_frames, regex.sub('.png', raw_frame)))
|
||||
# END WORKAROUND
|
||||
|
||||
# append input frames path into command
|
||||
execute.extend([
|
||||
'-i',
|
||||
|
||||
Reference in New Issue
Block a user