mirror of
https://github.com/k4yt3x/video2x.git
synced 2024-12-28 06:59:11 +00:00
tests(*): updated test file paths and removed unused dependencies
Signed-off-by: k4yt3x <i@k4yt3x.com>
This commit is contained in:
parent
7c70032fe7
commit
b4b7cadf0d
@ -1,9 +1,6 @@
|
||||
#!/usr/bin/python
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
import ctypes
|
||||
import multiprocessing
|
||||
import os
|
||||
from pathlib import Path
|
||||
|
||||
import utils
|
||||
@ -14,9 +11,11 @@ from video2x import Upscaler, Video2X
|
||||
|
||||
def test_upscaling():
|
||||
video2x = Video2X()
|
||||
output_path = Path("data/test_video_output.mp4")
|
||||
|
||||
output_path = Path("tests/data/test_video_output.mp4")
|
||||
|
||||
video2x.upscale(
|
||||
Path("data/test_video.mp4"),
|
||||
Path("tests/data/test_video.mp4"),
|
||||
output_path,
|
||||
None,
|
||||
720,
|
||||
@ -32,9 +31,9 @@ def test_upscale_image():
|
||||
# initialize upscaler instance
|
||||
upscaler = Upscaler()
|
||||
|
||||
image = Image.open("data/test_image.png")
|
||||
image = Image.open("tests/data/test_image.png")
|
||||
upscaled_image = upscaler.upscale_image(image, 1680, 960, "waifu2x", 3)
|
||||
reference_image = Image.open("data/test_image_ref.png")
|
||||
reference_image = Image.open("tests/data/test_image_ref.png")
|
||||
assert utils.get_image_diff(upscaled_image, reference_image) < 0.5
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user