1
0
Fork 0

fix(api): log tile size and overlap

This commit is contained in:
Sean Sube 2023-07-02 05:15:01 -05:00
parent 4b84188f6e
commit eef055eddd
Signed by: ssube
GPG Key ID: 3EED7B957D362AF1
2 changed files with 11 additions and 3 deletions

View File

@ -2,9 +2,9 @@ from typing import Optional
from PIL import Image
from onnx_web.params import ImageParams, Size, SizeChart, StageParams
from onnx_web.server.context import ServerContext
from onnx_web.worker.context import WorkerContext
from ..params import ImageParams, Size, SizeChart, StageParams
from ..server.context import ServerContext
from ..worker.context import WorkerContext
class BaseStage:

View File

@ -147,6 +147,14 @@ def process_tile_grid(
tiles_x = ceil(width / adj_tile)
tiles_y = ceil(height / adj_tile)
total = tiles_x * tiles_y
logger.debug(
"processing %s tiles (%s x %s) with adjusted size of %s, %s overlap",
total,
tiles_x,
tiles_y,
adj_tile,
overlap,
)
tiles: List[Tuple[int, int, Image.Image]] = []