Skip to content
Questa pagina non è ancora disponibile nella tua lingua. Viene mostrata la versione in inglese.

Deep Zoom and Gigapixel Images

Serve a tile pyramid as DZI and IIIF Image API 3.0, and paint brush masks at the source's full resolution with no texture-size ceiling.

Annotate images too large to send to a browser as one file — aerial surveys, stitched microscopy mosaics, scanned maps — with boxes, polygons and masks that work at any magnification. Potato serves a tile pyramid and layers the annotation canvas over it.

yaml
annotation_schemes:
  - annotation_type: image_annotation
    name: structures
    description: "Mark every structure."
    source_field: image
    viewer: deepzoom          # the default is `fabric`
    tools: [bbox, polygon, brush, eraser]
    labels:
      - {name: building, color: "#c0392b"}

media_directory is where the tile routes read from; paths in your data file are relative to it.

Runnable example: examples/image/deep-zoom/.

Two protocols, one pyramid

The same tile pyramid is served as both DZI and IIIF Image API 3.0. IIIF matters for cultural-heritage and digital-humanities work, where an institution's existing viewers and citation practices already assume it. Rendering is by OpenSeadragon, vendored locally like every other asset.

Masks at full resolution

Brush masks work on tiled images at the source's full resolution, because the mask buffer indexes image pixels rather than a GPU texture. There is no texture-size ceiling to hit.

This is worth stating carefully, because an earlier version of this claim was wrong and was corrected. Other platforms do support masking on tiled images; V7 among them. What is specific here is the buffer design, not the capability.

The buffers are sparse and chunked, which is what makes this affordable: ten classes on a 12-megapixel image went from about 458 MB to about 46 MB, and mask data stopped scaling with image area at all, holding at 16 KB regardless of resolution.

Where Potato is not the right tool

For digital pathology specifically, QuPath (desktop, open source, the field standard) and Cytomine (web, open source, multi-user with blind annotation) are purpose-built, and Potato does not read SVS, DICOM or NIfTI. Use Potato here when your images are large but not clinical-format, or when you need its agreement and workflow layers on top.