made custom intermediate frame format available for waifu2x/srmd/realsr

This commit is contained in:
K4YT3X 2020-09-21 15:14:00 -04:00
parent 7de9cc699a
commit a0522311e2
4 changed files with 14 additions and 7 deletions

View File

@ -1,7 +1,7 @@
# Name: Video2X Configuration File # Name: Video2X Configuration File
# Creator: K4YT3X # Creator: K4YT3X
# Date Created: October 23, 2018 # Date Created: October 23, 2018
# Last Modified: September 13, 2020 # Last Modified: September 21, 2020
# Values here are the default values. Change the value here to # Values here are the default values. Change the value here to
# save the default value permanently. # save the default value permanently.
# Items commented out are parameters irrelevant to this context # Items commented out are parameters irrelevant to this context
@ -32,7 +32,7 @@ waifu2x_converter_cpp:
#list-supported-formats: null # dump currently supported format list #list-supported-formats: null # dump currently supported format list
#list-opencv-formats: null # (deprecated. Use --list-supported-formats) dump opencv supported format list #list-opencv-formats: null # (deprecated. Use --list-supported-formats) dump opencv supported format list
#list-processor # dump processor list #list-processor # dump processor list
output-format: null # The format used when running in recursive/folder mode #output-format: null # The format used when running in recursive/folder mode
png-compression: 5 # Set PNG compression level (0-9), 9 = Max compression (slowest & smallest) png-compression: 5 # Set PNG compression level (0-9), 9 = Max compression (slowest & smallest)
image-quality: -1 # JPEG & WebP Compression quality (-1-101, 0 being smallest size and lowest quality, -1 being default), use 101 for lossless WebP image-quality: -1 # JPEG & WebP Compression quality (-1-101, 0 being smallest size and lowest quality, -1 being default), use 101 for lossless WebP
block-size: 0 # block size block-size: 0 # block size
@ -64,7 +64,7 @@ waifu2x_ncnn_vulkan:
g: 0 # gpu-id: gpu device to use (default=0) g: 0 # gpu-id: gpu device to use (default=0)
j: '1:2:2' # thread count for load/proc/save (default=1:2:2) can be 1:2,2,2:2 for multi-gpu j: '1:2:2' # thread count for load/proc/save (default=1:2:2) can be 1:2,2,2:2 for multi-gpu
x: false # enable tta mode x: false # enable tta mode
f: png # output image format (jpg/png/webp, default=ext/png) #f: png # output image format (jpg/png/webp, default=ext/png)
srmd_ncnn_vulkan: srmd_ncnn_vulkan:
path: '%LOCALAPPDATA%\video2x\srmd-ncnn-vulkan\srmd-ncnn-vulkan' path: '%LOCALAPPDATA%\video2x\srmd-ncnn-vulkan\srmd-ncnn-vulkan'
v: null # verbose output v: null # verbose output
@ -77,6 +77,7 @@ srmd_ncnn_vulkan:
g: 0 # gpu device to use (default=0) g: 0 # gpu device to use (default=0)
j: '1:2:2' # thread count for load/proc/save (default=1:2:2) j: '1:2:2' # thread count for load/proc/save (default=1:2:2)
x: false # enable tta mode x: false # enable tta mode
#f: png # output image format (jpg/png/webp, default=ext/png)
realsr_ncnn_vulkan: realsr_ncnn_vulkan:
path: '%LOCALAPPDATA%\video2x\realsr-ncnn-vulkan\realsr-ncnn-vulkan' path: '%LOCALAPPDATA%\video2x\realsr-ncnn-vulkan\realsr-ncnn-vulkan'
v: null # verbose output v: null # verbose output
@ -88,6 +89,7 @@ realsr_ncnn_vulkan:
g: 0 # gpu device to use (default=0) g: 0 # gpu device to use (default=0)
j: '1:2:2' # thread count for load/proc/save (default=1:2:2) j: '1:2:2' # thread count for load/proc/save (default=1:2:2)
x: false # enable tta mode x: false # enable tta mode
#f: png # output image format (jpg/png/webp, default=ext/png)
anime4kcpp: anime4kcpp:
path: '%LOCALAPPDATA%\video2x\anime4kcpp\CLI\Anime4KCPP_CLI\Anime4KCPP_CLI' path: '%LOCALAPPDATA%\video2x\anime4kcpp\CLI\Anime4KCPP_CLI\Anime4KCPP_CLI'
#input: null # File for loading (string [=./pic/p1.png]) #input: null # File for loading (string [=./pic/p1.png])

View File

@ -4,7 +4,7 @@
Name: RealSR NCNN Vulkan Driver Name: RealSR NCNN Vulkan Driver
Creator: K4YT3X Creator: K4YT3X
Date Created: May 26, 2020 Date Created: May 26, 2020
Last Modified: September 9, 2020 Last Modified: September 21, 2020
Description: This class is a high-level wrapper Description: This class is a high-level wrapper
for realsr_ncnn_vulkan. for realsr_ncnn_vulkan.
@ -49,11 +49,13 @@ class WrapperMain:
parser.add_argument('-g', type=int, help='gpu device to use') parser.add_argument('-g', type=int, help='gpu device to use')
parser.add_argument('-j', type=str, help='thread count for load/proc/save') parser.add_argument('-j', type=str, help='thread count for load/proc/save')
parser.add_argument('-x', action='store_true', help='enable tta mode') parser.add_argument('-x', action='store_true', help='enable tta mode')
parser.add_argument('-f', type=str, help=argparse.SUPPRESS) # help='output image format (jpg/png/webp, default=ext/png)')
return parser.parse_args(arguments) return parser.parse_args(arguments)
def load_configurations(self, upscaler): def load_configurations(self, upscaler):
# self.driver_settings['s'] = int(upscaler.scale_ratio) # self.driver_settings['s'] = int(upscaler.scale_ratio)
self.driver_settings['j'] = '{}:{}:{}'.format(upscaler.processes, upscaler.processes, upscaler.processes) self.driver_settings['j'] = '{}:{}:{}'.format(upscaler.processes, upscaler.processes, upscaler.processes)
self.driver_settings['f'] = upscaler.extracted_frame_format.lower()
def set_scale_ratio(self, scale_ratio: int): def set_scale_ratio(self, scale_ratio: int):
self.driver_settings['s'] = int(scale_ratio) self.driver_settings['s'] = int(scale_ratio)

View File

@ -4,7 +4,7 @@
Name: SRMD NCNN Vulkan Driver Name: SRMD NCNN Vulkan Driver
Creator: K4YT3X Creator: K4YT3X
Date Created: April 26, 2020 Date Created: April 26, 2020
Last Modified: September 9, 2020 Last Modified: September 21, 2020
Description: This class is a high-level wrapper Description: This class is a high-level wrapper
for srmd_ncnn_vulkan. for srmd_ncnn_vulkan.
@ -50,11 +50,13 @@ class WrapperMain:
parser.add_argument('-g', type=int, help='gpu device to use') parser.add_argument('-g', type=int, help='gpu device to use')
parser.add_argument('-j', type=str, help='thread count for load/proc/save') parser.add_argument('-j', type=str, help='thread count for load/proc/save')
parser.add_argument('-x', action='store_true', help='enable tta mode') parser.add_argument('-x', action='store_true', help='enable tta mode')
parser.add_argument('-f', type=str, help=argparse.SUPPRESS) # help='output image format (jpg/png/webp, default=ext/png)')
return parser.parse_args(arguments) return parser.parse_args(arguments)
def load_configurations(self, upscaler): def load_configurations(self, upscaler):
# self.driver_settings['s'] = int(upscaler.scale_ratio) # self.driver_settings['s'] = int(upscaler.scale_ratio)
self.driver_settings['j'] = '{}:{}:{}'.format(upscaler.processes, upscaler.processes, upscaler.processes) self.driver_settings['j'] = '{}:{}:{}'.format(upscaler.processes, upscaler.processes, upscaler.processes)
self.driver_settings['f'] = upscaler.extracted_frame_format.lower()
def set_scale_ratio(self, scale_ratio: int): def set_scale_ratio(self, scale_ratio: int):
self.driver_settings['s'] = int(scale_ratio) self.driver_settings['s'] = int(scale_ratio)

View File

@ -7,7 +7,7 @@ Date Created: June 26, 2019
Last Modified: May 11, 2020 Last Modified: May 11, 2020
Editor: K4YT3X Editor: K4YT3X
Last Modified: September 9, 2020 Last Modified: September 21, 2020
Description: This class is a high-level wrapper Description: This class is a high-level wrapper
for waifu2x_ncnn_vulkan. for waifu2x_ncnn_vulkan.
@ -53,12 +53,13 @@ class WrapperMain:
parser.add_argument('-g', type=int, help='gpu device to use') parser.add_argument('-g', type=int, help='gpu device to use')
parser.add_argument('-j', type=str, help='thread count for load/proc/save') parser.add_argument('-j', type=str, help='thread count for load/proc/save')
parser.add_argument('-x', action='store_true', help='enable tta mode') parser.add_argument('-x', action='store_true', help='enable tta mode')
parser.add_argument('-f', type=str, help='output image format (jpg/png/webp, default=ext/png)') parser.add_argument('-f', type=str, help=argparse.SUPPRESS) # help='output image format (jpg/png/webp, default=ext/png)')
return parser.parse_args(arguments) return parser.parse_args(arguments)
def load_configurations(self, upscaler): def load_configurations(self, upscaler):
# self.driver_settings['s'] = int(upscaler.scale_ratio) # self.driver_settings['s'] = int(upscaler.scale_ratio)
self.driver_settings['j'] = '{}:{}:{}'.format(upscaler.processes, upscaler.processes, upscaler.processes) self.driver_settings['j'] = '{}:{}:{}'.format(upscaler.processes, upscaler.processes, upscaler.processes)
self.driver_settings['f'] = upscaler.extracted_frame_format.lower()
def set_scale_ratio(self, scale_ratio: int): def set_scale_ratio(self, scale_ratio: int):
self.driver_settings['s'] = int(scale_ratio) self.driver_settings['s'] = int(scale_ratio)