Particle Classification
Python scripts for particle classification
Used by particle trieur to perform model training.
Installation
conda create -n miso python=3.9
conda activate miso
conda install -c conda-forge cudatoolkit=11.2 cudnn=8.1.0
pip install tensorflow==2.10.1
pip install miso
Updating
conda activate miso
pip install -U miso
Command line interface (CLI)
Train a model
TBD
Classify a folder of images
Classifies a folder of images and saves the result in a CSV. This CSV can be imported into Particle Trieur. If the images are organised by sample into subfolders it will use the subfolder name as the sample name, else specify the sample name manually.
Usage: python -m miso classify-folder [OPTIONS]
Classify images in a folder and output the results to a CSV file.
Options:
-m, --model PATH Path to the model information. [required]
-i, --input PATH Path to the directory containing images.
[required]
-o, --output PATH Path where the output CSV will be saved.
[required]
-b, --batch_size INTEGER Batch size for processing images. [default:
32]
-s, --sample TEXT Default sample name if not using
subdirectories. [default: unknown]
-u, --unsure_threshold FLOAT Threshold below which predictions are
considered unsure. [default: 0.0]
Morphology of a folder of plankton images
Does morphology on a folder of plankton images and saves the result in a CSV. This CSV can be imported into Particle Trieur as parameters. If the images are organised by sample into subfolders it will use the subfolder name as the sample name, else specify the sample name manually.
The plankton model must first be downloaded from here: https://1drv.ms/f/s!AiQM7sVIv7fanuNzfcw2O8kAnDU26Q?e=NA5ztG
Make sure to put the model.onnx and the model_info.xml files in the same folder
Usage: python -m miso segment-folder [OPTIONS]
Segment images in a folder and output the results.
Options:
-m, --model PATH Path to the model information. [required]
-i, --input PATH Path to the folder containing images. [required]
-o, --output PATH Path where the morphology csv will be saved.
[required]
-b, --batch_size INTEGER Batch size for processing images. [default: 32]
-s, --sample TEXT Default sample name [default: unknown]
-t, --threshold FLOAT Threshold for segmentation. [default: 0.5]
--save-contours Whether to save contours or not.
Metadata
Release files for miso 3.1.25
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 |
|---|---|---|---|---|
| miso-3.1.25.tar.gz | 84.4 kB | Without provenance | Details for miso-3.1.25.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| miso-3.1.25-py3-none-any.whl | Python 3 | none | any | Details for miso-3.1.25-py3-none-any.whl |
Total release size: 190.5 kB
Release files / miso-3.1.25.tar.gz
| Download URL | miso-3.1.25.tar.gz |
|---|---|
| Size | 84.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
176ba208c5fd3b6b99688f045744f018af80bea04e70b649da530f0179688e71
|
|
BLAKE2b-256 checksum How to use checksums |
f7ac77e14f72339a56bf8098fe30d56566e358fb21cce28a1adbce0c99ed9182
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/5.1.1 CPython/3.12.5
|
Release files / miso-3.1.25-py3-none-any.whl
| Download URL | miso-3.1.25-py3-none-any.whl |
|---|---|
| Size | 106.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5689338a0fc4834d68d94f204ec3a93abb8951ed6dd43de1f571cd1f40e2795d
|
|
BLAKE2b-256 checksum How to use checksums |
e654ee99a75700f501519f460d3638f6543c87b047b25940375b03b918cc3696
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/5.1.1 CPython/3.12.5
|
Security for miso 3.1.25
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.