From eeebdfebcb774cb6fa40b3ee6d46e438c7f58d07 Mon Sep 17 00:00:00 2001 From: Sean Sube Date: Mon, 11 Sep 2023 17:37:20 -0500 Subject: [PATCH] set unlimited tile to large value, clarify variable names --- api/onnx_web/chain/base.py | 4 ++-- api/onnx_web/params.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/api/onnx_web/chain/base.py b/api/onnx_web/chain/base.py index 077f5998..a62d6fcb 100644 --- a/api/onnx_web/chain/base.py +++ b/api/onnx_web/chain/base.py @@ -209,8 +209,8 @@ class ChainPipeline: if len(extra_tiles) > 1: for layer in extra_tiles: layer_output = Image.new("RGB", output.size) - for tile, dims in layer: - layer_output.paste(tile, (dims[0], dims[1])) + for layer_tile, dims in layer: + layer_output.paste(layer_tile, (dims[0], dims[1])) stage_outputs.append(layer_output) diff --git a/api/onnx_web/params.py b/api/onnx_web/params.py index 4b03f758..a6f2c888 100644 --- a/api/onnx_web/params.py +++ b/api/onnx_web/params.py @@ -14,7 +14,6 @@ Point = Tuple[int, int] class SizeChart(IntEnum): - unlimited = 0 mini = 128 # small tile for very expensive models half = 256 # half tile for outpainting auto = 512 # auto tile size @@ -25,6 +24,7 @@ class SizeChart(IntEnum): hd16k = 2**14 hd32k = 2**15 hd64k = 2**16 + unlimited = 2**32 # sort of class TileOrder: