BCT
Machine learning toolkit designed to support data scientists in breast cancer detection, classification and analysis.
Installation
Install the package with:
pip install breast-cancer-toolkit
Usage as CLI
Convert the DCM files into TIFF format recursively with the same basename.
parallel bct convert {} {.}.tiff ::: **/*.dcm
Usage as library
Models
Remove background with instance segmentation
| Model | Training data | Resolution | # of samples seen | IoU | Accuracy |
|---|---|---|---|---|---|
Data sources
| Source | Argument | Type | Notes |
|---|---|---|---|
| image | 'image.jpg' | str or Path | Single image file. Format supported: jgp, png, dcm, tiff |
| URL | 'https://ultralytics.com/images/bus.jpg' | str | URL to an image. |
| screenshot | 'screen' | str | Capture a screenshot. |
| PIL | Image.open('im.jpg') | PIL.Image | HWC format with RGB channels. |
| OpenCV | cv2.imread('im.jpg') | np.ndarray | HWC format with BGR channels uint8 (0-255). |
| numpy | np.zeros((640,1280,3)) | np.ndarray | HWC format with BGR channels uint8 (0-255). |
| torch | torch.zeros(16,3,320,640) | torch.Tensor | BCHW format with RGB channels float32 (0.0-1.0). |
| CSV, json, xlsx | 'sources.csv' | str or Path | CSV file containing paths to images, videos, or directories. |
| video | 'video.mp4' | str or Path | Video file in formats like MP4, AVI, etc. |
| directory | 'path/' | str or Path | Path to a directory containing images or videos. |
| glob | 'path/*.jpg' | str | Glob pattern to match multiple files. Use the * character as a wildcard. |
| YouTube | 'https://youtu.be/LNwODJXcvt4' | str | URL to a YouTube video. |
| stream | 'rtsp://example.com/media.mp4' | str | URL for streaming protocols such as RTSP, RTMP, TCP, or an IP address. |
| multi-stream | 'list.streams' | str or Path | *.streams text file with one stream URL per row, i.e. 8 streams will run at batch-size 8. |
Note
This project has been set up using PyScaffold 4.5 and the dsproject extension 0.0.post1.dev166+g2aaddf7.d20240514.
Metadata
Release files for breast-cancer-toolkit 1.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| breast_cancer_toolkit-1.1.0.tar.gz | 32.2 kB | Without provenance | Details for breast_cancer_toolkit-1.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| breast_cancer_toolkit-1.1.0-py3-none-any.whl | Python 3 | none | any | Details for breast_cancer_toolkit-1.1.0-py3-none-any.whl |
Total release size: 43.0 kB
Release files / breast_cancer_toolkit-1.1.0.tar.gz
| Download URL | breast_cancer_toolkit-1.1.0.tar.gz |
|---|---|
| Size | 32.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ba3431f10eb0422d97f40c476ca051deca375fc71c9a62ab2b895b07aeb2f666
|
|
BLAKE2b-256 checksum How to use checksums |
d84592c1ad6353f62a2c6f64b0c52c17b868c425e216021d271c8a0fd6b722f0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.11.9
|
Release files / breast_cancer_toolkit-1.1.0-py3-none-any.whl
| Download URL | breast_cancer_toolkit-1.1.0-py3-none-any.whl |
|---|---|
| Size | 10.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
52c1ee9f0022b05c8014794f769a4b053d09421f8c11037cbe2e964ec1d60690
|
|
BLAKE2b-256 checksum How to use checksums |
5b209f79b5dd64a2fb1c9fb329acc081ff8c2c40bdc0e7ab0347165cd2c99080
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.11.9
|
Security for breast-cancer-toolkit 1.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.