A plugin to send and receive image data for visualization in Napari from other applications
Project description
napari-stream
A plugin to send and receive image data for visualization in Napari from other applications.
napari-stream lets you push images from any application, process, or codebase into a running napari instance—even from another machine. It can automatically pull array-like data (NumPy, PyTorch tensors, zarr arrays, etc.) from nested Python lists and dicts, so you can stream complex structures without manual extraction. You can keep things private (local IPC/loopback) or make the receiver reachable publicly over TCP. The receiver endpoint can also be set via the NAPARI_STREAM_ENDPOINT environment variable.
Quick usage
from napari_stream.sender import StreamSender, send
import numpy as np
# Option 1: explicit sender (recommended when reusing across many sends)
sender = StreamSender(endpoint="tcp://192.0.2.10:5556") # or leave None to use NAPARI_STREAM_ENDPOINT/default
sender.send(np.random.rand(256, 256), name="image")
# Option 2: convenience function; pass connection kwargs through
send(np.random.rand(64, 64), name="quick", endpoint="tcp://127.0.0.1:5556")
On the receiving side, open the napari dock widget, choose your endpoint, and toggle public access if you want to accept connections from other machines.
Installation
You can install napari-stream via pip:
pip install napari-stream
If napari is not already installed, you can install napari-stream with napari and Qt via:
pip install "napari-stream[all]"
Contributing
Contributions are very welcome. Tests can be run with tox, please ensure the coverage at least stays the same before you submit a pull request.
License
Distributed under the terms of the MIT license, "napari-stream" is free and open source software
Issues
If you encounter any problems, please [file an issue] along with a detailed description.
Acknowledgments
This repository is developed and maintained by the Applied Computer Vision Lab (ACVL) of Helmholtz Imaging and the Division of Medical Image Computing at DKFZ.
This repository was generated with copier using the napari-plugin-template.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file napari_stream-0.0.9.tar.gz.
File metadata
- Download URL: napari_stream-0.0.9.tar.gz
- Upload date:
- Size: 22.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c2f58e64f8862eb0d1af7a2589cef7db6f3d3f7a8ba6e6aacfbfa2991f566513
|
|
| MD5 |
7d45e962ba4d19b8e6b5909fe83f0676
|
|
| BLAKE2b-256 |
dd1b39e566abff621b232cf4c4cc39bda5d6647b65951f0242c07c8f02362510
|
Provenance
The following attestation bundles were made for napari_stream-0.0.9.tar.gz:
Publisher:
test_and_deploy.yml on MIC-DKFZ/napari-stream
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
napari_stream-0.0.9.tar.gz -
Subject digest:
c2f58e64f8862eb0d1af7a2589cef7db6f3d3f7a8ba6e6aacfbfa2991f566513 - Sigstore transparency entry: 760206265
- Sigstore integration time:
-
Permalink:
MIC-DKFZ/napari-stream@39e05f1be059150730f48e034b2f3749674a4efd -
Branch / Tag:
refs/tags/v0.0.9 - Owner: https://github.com/MIC-DKFZ
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
test_and_deploy.yml@39e05f1be059150730f48e034b2f3749674a4efd -
Trigger Event:
push
-
Statement type:
File details
Details for the file napari_stream-0.0.9-py3-none-any.whl.
File metadata
- Download URL: napari_stream-0.0.9-py3-none-any.whl
- Upload date:
- Size: 16.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ad17df224b3b16203bfcaf10bec29c9bc2cf348bb30167fb2609cd5e4229d700
|
|
| MD5 |
7c760081240f04d1d63b4be8e43af407
|
|
| BLAKE2b-256 |
63c2a759dff4ac142ddc292c1733e3f141d4ff98e48be0f1f4653739cd5a541c
|
Provenance
The following attestation bundles were made for napari_stream-0.0.9-py3-none-any.whl:
Publisher:
test_and_deploy.yml on MIC-DKFZ/napari-stream
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
napari_stream-0.0.9-py3-none-any.whl -
Subject digest:
ad17df224b3b16203bfcaf10bec29c9bc2cf348bb30167fb2609cd5e4229d700 - Sigstore transparency entry: 760206272
- Sigstore integration time:
-
Permalink:
MIC-DKFZ/napari-stream@39e05f1be059150730f48e034b2f3749674a4efd -
Branch / Tag:
refs/tags/v0.0.9 - Owner: https://github.com/MIC-DKFZ
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
test_and_deploy.yml@39e05f1be059150730f48e034b2f3749674a4efd -
Trigger Event:
push
-
Statement type: