patching waifu2x-converter-cpp libw2xc.so not found issue

This commit is contained in:
K4YT3X 2020-06-13 05:09:10 -04:00
parent 6e1315f2ed
commit 1eba4f2187

View File

@ -4,7 +4,7 @@
Name: Waifu2x Converter CPP Driver
Author: K4YT3X
Date Created: February 8, 2019
Last Modified: June 7, 2020
Last Modified: June 13, 2020
Description: This class is a high-level wrapper
for waifu2x-converter-cpp.
@ -82,6 +82,10 @@ class WrapperMain:
threads {int} -- number of threads
"""
# waifu2x-converter-cpp cannot fine libw2xc.so under Linux
# if the working directory is not waifu2x-converter-cpp's directory
os.chdir(pathlib.Path(self.driver_settings['path']).parent)
# overwrite config file settings
self.driver_settings['input'] = input_directory
self.driver_settings['output'] = output_directory