Skip to main content

Python scripts for training CNNs for particle classification

Project description

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]

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

miso-3.1.17.tar.gz (80.8 kB view hashes)

Uploaded Source

Built Distribution

miso-3.1.17-py3-none-any.whl (102.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page