upscale
Enlarge or restore a single image using an installed model, then write the result to the configured write root.
Instructions
Upscale (or restore) one image with one model, writing the result under the write root.
Returns the job's status. When the job is done, `result` holds the output
path, sizes, model details, device and timing.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| half | No | Run in float16 on the GPU (faster, less memory) if the model supports it. | |
| input | Yes | Input image: absolute path inside a read root, or relative to the first read root. Anything Pillow reads, plus HEIC/HEIF/AVIF and 16-bit PNG/TIFF (kept at 16 bits). | |
| model | Yes | Model file name or stem from list_models, e.g. 'RealESRGAN_x4plus'. | |
| output | No | Output path (absolute inside the write root, or relative to it). The suffix picks the format: .png .jpg .tif .webp; .png and .tif keep 16 bits for a deeper source. Default: <input stem>.<model stem>.<scale>.png in the write root. | |
| overwrite | No | Replace an existing output file. | |
| tile_size | No | Tile edge in input pixels; 0 = whole image in one pass. | |
| jpeg_quality | No | Quality for .jpg output. | |
| output_scale | No | Final size relative to the INPUT. Omit to keep the model's native scale (4x for a 4x model). 1 = resize back to the input size (for compositing over the original). Other values resize to that multiple with LANCZOS. | |
| tile_overlap | No | Context margin around each tile, in input pixels, to hide seams. | |
| wait_seconds | No | Seconds to wait for the job to finish before returning. Omit to wait until it is done. 0 returns the job id at once. A client that times out calls after about a minute should pass about 45 and poll job_status while the status is queued or running. |