feat(gigapixel): Update for the version bump and enable face recovery
This commit is contained in:
1 parent
b913274f87
commit
9e2659d3f1
1 file changed
+18
-4
+18
-4
@@ -6,14 +6,27 @@
|
|||||||
import argparse
|
import argparse
|
||||||
import logging
|
import logging
|
||||||
import subprocess
|
import subprocess
|
||||||
|
from pathlib import Path
|
||||||
from threading import Thread
|
from threading import Thread
|
||||||
from typing import Callable
|
from typing import Callable
|
||||||
from pathlib import Path
|
|
||||||
|
|
||||||
GIGAPIXEL_EXE = Path(
|
GIGAPIXEL_EXE = Path("/Applications/Topaz Gigapixel.app/Contents/MacOS/Topaz Gigapixel")
|
||||||
"/Applications/Topaz Gigapixel AI.app/Contents/MacOS/Topaz Gigapixel AI"
|
|
||||||
)
|
|
||||||
MAX_LENGTH = 4000
|
MAX_LENGTH = 4000
|
||||||
|
FACE_RECOVERY_ARGS = [
|
||||||
|
"--sharpen",
|
||||||
|
"1",
|
||||||
|
"--denoise",
|
||||||
|
"4",
|
||||||
|
"--compression",
|
||||||
|
"1",
|
||||||
|
"--fr",
|
||||||
|
"60",
|
||||||
|
"--frv",
|
||||||
|
"2",
|
||||||
|
"--frc",
|
||||||
|
"0",
|
||||||
|
"--gamma-correction",
|
||||||
|
]
|
||||||
|
|
||||||
|
|
||||||
def parse_args() -> argparse.Namespace:
|
def parse_args() -> argparse.Namespace:
|
||||||
@@ -91,6 +104,7 @@ def upscale_images(
|
|||||||
output_format,
|
output_format,
|
||||||
"--suffix",
|
"--suffix",
|
||||||
"-upscaled",
|
"-upscaled",
|
||||||
|
*FACE_RECOVERY_ARGS,
|
||||||
]
|
]
|
||||||
|
|
||||||
if output_format == "jpg":
|
if output_format == "jpg":
|
||||||
|
|||||||
Reference in new issue
Block a user