fix(api): pass outscale factor to CodeFormer (fixes #100)
This commit is contained in:
parent
85b2895f41
commit
ca2f0a6404
|
@ -15,7 +15,7 @@ device = "cpu"
|
||||||
def correct_codeformer(
|
def correct_codeformer(
|
||||||
job: JobContext,
|
job: JobContext,
|
||||||
_server: ServerContext,
|
_server: ServerContext,
|
||||||
_stage: StageParams,
|
stage: StageParams,
|
||||||
_params: ImageParams,
|
_params: ImageParams,
|
||||||
source: Image.Image,
|
source: Image.Image,
|
||||||
*,
|
*,
|
||||||
|
@ -26,5 +26,5 @@ def correct_codeformer(
|
||||||
# TODO: terrible names, fix
|
# TODO: terrible names, fix
|
||||||
image = source or source_image
|
image = source or source_image
|
||||||
|
|
||||||
pipe = CodeFormer().to(device.torch_device())
|
pipe = CodeFormer(upscale=stage.outscale).to(device.torch_device())
|
||||||
return pipe(image)
|
return pipe(image)
|
||||||
|
|
Loading…
Reference in New Issue