Skip to main content

A trame package to display, manipulate, and select regions in images.

Project description

trame-image-tools

A set of trame widgets to create a zoom and pan 2D image environment that includes interactive area selection widgets.

demo_image

Install

pip install trame-image-tools

Usage

from trame_image_tools.widgets import (
    TrameImage,
    TrameImageRoi,
    TrameImageLine,
    TrameImageCircle,
    TrameImagePolygon,
    TrameImageGrid,
)

with TrameImage(
    src="https://www.kitware.com/main/wp-content/uploads/2023/10/logo-trame.png",
    size=("size", [800, 210]),
):
    TrameImageGrid(
        spacing=("grid_spacing", [50, 25]),  # [x_tick_spacing, y_tick_spacing]
    )

    TrameImageLine(
        v_model=("line", [200, 50, 300, 150]),  # [x0, y0, x1, y1, ...]
    )

    TrameImageRoi(
        v_model=("roi", [350, 50, 100, 100]),  # [x, y, width, height]
    )

    TrameImageCircle(
        v_model=("circle", [550, 100, 50]),  # [x, y, radius]
    )

    TrameImagePolygon(
        v_model=("polygon", [650, 90, 670, 150, 730, 150, 750, 90, 700, 50]),  # [x0, y0, x1, y1, ...]
    )

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

trame_image_tools-1.0.1.tar.gz (15.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

trame_image_tools-1.0.1-py3-none-any.whl (15.8 kB view details)

Uploaded Python 3

File details

Details for the file trame_image_tools-1.0.1.tar.gz.

File metadata

  • Download URL: trame_image_tools-1.0.1.tar.gz
  • Upload date:
  • Size: 15.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for trame_image_tools-1.0.1.tar.gz
Algorithm Hash digest
SHA256 3f14d6cc154e872ce934ba618904ad6ec27211e689966c5278a87352b1fed1c4
MD5 be1aba0af9d93400125399d414bce3a2
BLAKE2b-256 f1a7e445f9e5f770a8fb3ab2fc6cdc8696b6d6805b9092ffce65570846b4b32a

See more details on using hashes here.

Provenance

The following attestation bundles were made for trame_image_tools-1.0.1.tar.gz:

Publisher: test_and_release.yml on Kitware/trame-image-tools

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file trame_image_tools-1.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for trame_image_tools-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 efb2e81bbb5c9cd494034b28075f529d601be7c009b08583e9972d325ddab737
MD5 668d1006a3840848fdbf2b578aaf5741
BLAKE2b-256 e2ac5ab941c202c096b83bd4a7b11ba72e7de3f3b7c980c3c638b359227caf40

See more details on using hashes here.

Provenance

The following attestation bundles were made for trame_image_tools-1.0.1-py3-none-any.whl:

Publisher: test_and_release.yml on Kitware/trame-image-tools

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page