Downloads#

This page contains downloadable scripts, notebooks, and utilities for PhenoTypic.

phenotypic-cli.py

Backwards compatibility wrapper for phenotypic-cli.py.

SLURM Job Chain Manager for Image Processing

Processes multiple directories sequentially with dependencies USAGE With directory file

Downloadable Notebooks#

Tutorial 1: Your First Plate Image

Welcome to PhenoTypic! In this tutorial, you will load your first agar plate image, understand the difference between the base Image and the grid-aware GridImage classes, and explore the accessor pattern that gives you different views of the same image.

Tutorial 2: Detecting Colonies

In [Tutorial 1](01_your_first_plate_image.ipynb), you loaded a plate image and explored its accessors. Now let’s put that plate to work — we’ll detect the individual Rhodotorula colonies using PhenoTypic’s OtsuDetector.

Tutorial 3: Enhancing Before Detection

Detection operates on detect_mat – a grayscale representation of your plate that the detector reads to separate colonies from background. If you improve detect_mat before running detection, you get cleaner, more complete results.

Tutorial 4: Building a Pipeline

Learning goals:

Tutorial 5: Working with Detected Grid Plates

In [Tutorial 1](01_your_first_plate_image.ipynb), you saw that most arrayed colony workflows use GridImage: an Image with row-and-column plate layout. This tutorial picks up after detection, when that grid layout becomes biologically useful.

Tutorial 6: Batch Processing

When you have dozens or hundreds of plates to process, running Python code one image at a time is not practical. PhenoTypic’s command-line interface (CLI) lets you apply a saved pipeline to an entire directory of plate images with built-in parallelism, checkpointing, and resume.

Tutorial 7: Measuring and Exporting

Detection tells you where colonies are. Measurement tells you what they are — how big, how round, how bright. In this tutorial you will add measurements to a pipeline, extract a DataFrame of colony features, and export the results for downstream analysis.

Tutorial 8: Using Prefab Pipelines

Building a pipeline from scratch gives you full control, but PhenoTypic also ships prefab pipelines — pre-configured ImagePipeline subclasses tuned for common organisms and plate types. In this tutorial you will survey the available prefabs, apply one, and compare results.

Tutorial 9: Diagnosing Image Quality

Before building a pipeline, it helps to assess the quality of your plate images. PhenoTypic’s diagnostics plotter gives you objective metrics for noise, contrast, and structure — so you can make informed decisions about which enhancers and detectors to use.

Tutorial 10: Detecting Filamentous Fungi

Filamentous fungi like Neurospora grow as branching networks of hyphae, not compact round colonies. Standard threshold detectors struggle with this morphology because hyphae are thin and have varying intensity. PhenoTypic includes a specialized pipeline for exactly this scenario.

How To: Assess Image Quality Before Pipeline Design

Run diagnostics on a plate image to objectively assess noise, contrast, and structure before choosing enhancers and detectors.

How To: Choose a Detection Algorithm

PhenoTypic offers multiple detectors, each suited to different plate conditions. This guide compares the most commonly used options on the same plate image so you can pick the right one.

How To: Combine Detectors with CompositeDetector

When no single detector captures all colonies reliably, combine multiple detectors using CompositeDetector. It merges their results via union, intersection, or overlap.

How To: Correct Edge Effects in Plate Assays

Colonies on the outer rows and columns of an agar plate often grow differently due to temperature gradients and humidity effects. Use EdgeCorrector to statistically identify and correct these biases.

How To: Correct Grid Rotation

Apply GridAligner to straighten plates that were scanned at a slight angle. This improves grid detection accuracy for downstream well-level analysis.

How To: Crop and Pad Images for Batch Consistency

Use ImageCropper to remove scanner borders and ImagePadder to make images a uniform size for batch processing.

How To: Denoise Low-Light Images

Low-light or high-ISO plate images contain noise that confuses detectors. PhenoTypic offers several denoising approaches, each with different tradeoffs between speed and quality.

How To: Enhance Low-Contrast Images

When colonies are faint or the agar background is uneven, detection suffers. Use CLAHE, ContrastStretching, or HomomorphicFilter to boost local contrast in detect_mat before detection.

How To: Fit Logistic Growth Models

Fit logistic growth curves to time-series colony measurements and extract kinetic parameters (growth rate, carrying capacity, lag time) using LogGrowthModel.

How To: Process Time-Series for Growth Curves

Process a series of plate images taken at different time points, extract measurements from each, and combine them into a time-series DataFrame suitable for growth curve analysis.

How To: Manual Grid Detection When Automatic Fails

When automatic grid detection does not find the correct grid layout, use ManualGridDetector to specify colony positions explicitly.

How To: Measure Colony Size and Intensity

Extract area, perimeter, circularity, and intensity statistics from detected colonies using MeasureSize, MeasureShape, and MeasureIntensity.

How To: Merge Fragmented Detections

When a single colony is split into multiple objects (fragmentation), use refiners to merge the fragments back together.

How To: Refine Noisy Detection Boundaries

After detection, colony masks often have ragged edges, small holes, or spurious fragments. Use refiners to clean up the mask before measuring.

Write Your First Custom Operation

PhenoTypic is designed to be extended. In this tutorial you will create a custom ImageEnhancer from scratch, implement its _operate() method, and use it inside an ImagePipeline.