Skip to main content

Client SDK for WSI embedding backend

Project description

WSI Embed Client SDK

Pip-installable frontend/client package for sending a local slide to the backend and saving embedding results on the user's machine.

1) Install

cd frontend
python -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"

Install from built wheel (recommended for remote client machines):

pip install squishy_wsi-0.1.0-py3-none-any.whl

2) Usage

Python API

from wsi_embed_client import embed

result = embed(
    slide_path="/path/to/slide.svs",
    model="titan-real-v1",
    key="team-key-123",
    server_url="http://your-gpu-server:8000",
)

print(result["embedding_id"])
print(result["saved_path"])

CLI

After install, use:

wsi-embed /path/to/slide.svs \
  --model titan-real-v1 \
  --key team-key-123 \
  --server-url http://your-gpu-server:8000

Optional flags:

  • --output-dir /path/to/save
  • --timeout-seconds 600
  • --print-json

What embed(...) does

  1. Zips the slide file locally.
  2. Sends the zip to the backend with X-API-Key.
  3. Receives embedding + metadata.
  4. Saves a rich JSON object to ./embeddings/ by default.

Saved filename format:

  • <slide>__<model>__<timestamp>__<shortid>.embedding.json

Supported model (validated)

The end-to-end path that is tested and validated is:

  • titan-real-v1

This corresponds to backend processing using TRIDENT patching + CONCH v1.5 patch features + TITAN slide aggregation.

3) Test

pytest -q

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

squishy_wsi-0.1.1.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

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

squishy_wsi-0.1.1-py3-none-any.whl (6.0 kB view details)

Uploaded Python 3

File details

Details for the file squishy_wsi-0.1.1.tar.gz.

File metadata

  • Download URL: squishy_wsi-0.1.1.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.8.3

File hashes

Hashes for squishy_wsi-0.1.1.tar.gz
Algorithm Hash digest
SHA256 3b748115d01232bfd67227bfaa05ceaed53961d522687a4db63d6e2c66ecbbd3
MD5 2aa50765292c066e42c0b8078bed6126
BLAKE2b-256 28b233a86ea035f5556e3646b99c1609cb5fa3a141f5f2e2845aa5e8e05c98e7

See more details on using hashes here.

File details

Details for the file squishy_wsi-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: squishy_wsi-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 6.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.8.3

File hashes

Hashes for squishy_wsi-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 6f0bb114fa473dc755896f422923aec4459d1b06ffc1c509ed9a3a79c9b08b87
MD5 0db0d64e59ee5ec6f76fbbeef97205e8
BLAKE2b-256 68aa81ef3c68208c765351a6c3af83857d4e646a8b1435760581fe88838f16ef

See more details on using hashes here.

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