A laboratory for exploring quantitative bioimage analysis in Python
Project description
QuBaLab
⚠️ Important
- 🆕 This is a new Python package for interacting with QuPath!
- 💻 For a stable, established solution, check out paquo (although we aim to meet different needs, see below)
- 🐛 Please report any bugs through the issues page
This is a Python package for exploring quantitative bioimage analysis... especially (but not exclusively) in combination with QuPath.
The name comes from Quantitative Bioimage Analysis Laboratory. This is chosen to be reminiscent of QuPath (Quantitative Pathology), but recognizes that neither is really restricted to pathology.
Why use QuBaLab?
QuBaLab isn't QuPath - they're just good friends.
- QuPath is a user-friendly Java application for bioimage analysis, which has some especially nice features for handling whole slide and highly-multiplexed images. But lots of bioimage analysis research is done in Python, and is hard to integrate with QuPath.
- QuBaLab's main aim is to help with this, by providing tools to help exchange data between QuPath and Python without any direct dependency on QuPath and Java. It therefore doesn't require QuPath to be installed, and can be used entirely from Python.
QuBaLab doesn't share code with QuPath, but is uses many of the same conventions for accessing images and representing objects in a GeoJSON compatible way. By using the same custom fields for things like measurements and classifications, exchanging data is much easier.
How does QuBaLab compare to paquo?
paquo is an existing library linking Python and QuPath that provides a pythonic interface to QuPath.
We think paquo is great - we don't want to replace it!
Here are the 3 main differences as we see them:
- Target audience
- paquo is written mostly for Python programmers who need to work with QuPath data
- QuBaLab is written mostly for QuPath users who want to dip into Python
- Convenience vs. Efficiency
- Pixel access
- paquo is for working with QuPath projects and objects - accessing pixels is beyond its scope (at least for now)
- QuBaLab enables requesting pixels as numpy or dask arrays, and provides functions to convert between thresholded images & QuPath objects
So if you're a Python programmer who needs an intuitive and efficient way to work with QuPath data, use paquo.
But if you're a QuPath user who wants to switch to Python for some tasks, including image processing, you might want to give QuBaLab a try.
Getting started
You can find the documentation on github pages.
This project contains the QuBaLab package in the qubalab folder. Take a look at the Installation section to install it.
Some notebooks in the notebooks folder demonstrate how to use QuBaLab. If you want to run them, you can take a look at the Development section. If you just want to browse the content in them, look at the documentation.
Installation
QuBaLab is on PyPI, so you can install it with pip:
pip install --upgrade qubalab
Development
This part is useful if you want to run the notebooks or contribute to this project.
First, run:
git clone https://github.com/qupath/qubalab.git # clone this repository
cd qubalab # go to the project directory
python -m venv ./.venv # create a local virual environment
source ./.venv/bin/activate # activate the venv
pip install -e ".[dev,test]" # install qubalab (-e means changes are loaded dynamically)
jupyter lab . # to start the Jupyter notebooks
pytest # to run unit tests
Project details
Release history Release notifications | RSS feed
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 qubalab-0.1.0.tar.gz.
File metadata
- Download URL: qubalab-0.1.0.tar.gz
- Upload date:
- Size: 34.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a7c82f2e3ee381ba25d312235b6dd8003088e4be16c71b612a825251e3db5482
|
|
| MD5 |
dd5d373dda6b3e74a2922611fc0cd02f
|
|
| BLAKE2b-256 |
686501c092a62ab7fea26de3f69d2869823bf54d15690d333d9a3aea721b7fbf
|
Provenance
The following attestation bundles were made for qubalab-0.1.0.tar.gz:
Publisher:
publish-release.yml on qupath/qubalab
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
qubalab-0.1.0.tar.gz -
Subject digest:
a7c82f2e3ee381ba25d312235b6dd8003088e4be16c71b612a825251e3db5482 - Sigstore transparency entry: 167469300
- Sigstore integration time:
-
Permalink:
qupath/qubalab@2031043acc7e4ca6a882feb99629d4b2c35a01c9 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/qupath
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-release.yml@2031043acc7e4ca6a882feb99629d4b2c35a01c9 -
Trigger Event:
release
-
Statement type:
File details
Details for the file qubalab-0.1.0-py3-none-any.whl.
File metadata
- Download URL: qubalab-0.1.0-py3-none-any.whl
- Upload date:
- Size: 40.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cef2327da6f28d6018d145285d3988588af1c4cabb1f3c3be2b73f652adef16e
|
|
| MD5 |
96c50880fb99252cac2027773b50160c
|
|
| BLAKE2b-256 |
d1c2825ca3940b9cbca080c2a29e43bdac1c292ec51ef87d193cdb6ecfe42c93
|
Provenance
The following attestation bundles were made for qubalab-0.1.0-py3-none-any.whl:
Publisher:
publish-release.yml on qupath/qubalab
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
qubalab-0.1.0-py3-none-any.whl -
Subject digest:
cef2327da6f28d6018d145285d3988588af1c4cabb1f3c3be2b73f652adef16e - Sigstore transparency entry: 167469301
- Sigstore integration time:
-
Permalink:
qupath/qubalab@2031043acc7e4ca6a882feb99629d4b2c35a01c9 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/qupath
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-release.yml@2031043acc7e4ca6a882feb99629d4b2c35a01c9 -
Trigger Event:
release
-
Statement type: