Automated pipeline for mitochondrial and lysosomal detection, tracking, morphology, and colocalization analysis in microscopy images.
Project description
AutoMorphoTrack
AutoMorphoTrack is a comprehensive, modular image-analysis pipeline for automated detection, morphology classification, shape profiling, motility tracking, and colocalization analysis of mitochondria and lysosomes in multichannel fluorescence microscopy data.
Developed by Armin Bayati, Ph.D.
Overview
AutoMorphoTrack processes time-lapse .tif stacks (typically two-channel: mitochondria + lysosomes) and generates publication-ready visual and quantitative outputs at every analysis step. The pipeline integrates seamlessly into scientific workflows and prioritizes transparency, reproducibility, and ease of use.
Key Features
- Automated organelle detection with morphological filtering
- Integrated tracking of mitochondria and lysosomes across time
- Shape profiling with publication-ready violin plots
- Motility analysis with velocity and displacement quantification
- Colocalization metrics (Manders, Pearson coefficients)
- Comprehensive validation tools for segmentation and tracking accuracy
- Colorblind-safe visualizations throughout
- High-resolution outputs (600 DPI publication-ready figures)
Installation
Via PyPI (Recommended)
pip install automorphotrack
From Source
git clone https://github.com/abayatibrain/AutoMorphoTrack.git
cd AutoMorphoTrack
pip install -e .
Development Install
git clone https://github.com/abayatibrain/AutoMorphoTrack.git
cd AutoMorphoTrack
pip install -e ".[dev]"
Quick Start
from automorphotrack import (
detect_organelles,
count_lysosomes_per_frame,
classify_morphology,
analyze_shape_features,
profile_shape_data,
track_organelles,
track_overlay,
analyze_motility,
analyze_colocalization,
summarize_integrated_data
)
tif_path = "path/to/Composite.tif"
# Run full pipeline
detect_organelles(tif_path)
count_lysosomes_per_frame(tif_path)
classify_morphology(tif_path)
analyze_shape_features(tif_path)
profile_shape_data()
track_organelles(tif_path)
track_overlay(tif_path)
analyze_motility()
analyze_colocalization(tif_path)
summarize_integrated_data()
Module Overview
| Module | Function | Inputs | Outputs | Purpose |
|---|---|---|---|---|
| detection | detect_organelles() |
TIF file | PNG, MP4, masks | Segment mitochondria and lysosomes |
| lyso_count | count_lysosomes_per_frame() |
TIF file | PNG, CSV, MP4 | Quantify lysosomes per frame |
| morphology | classify_morphology() |
TIF file | PNG, CSV, MP4 | Classify mitochondria as elongated vs. punctate |
| shape_features | analyze_shape_features() |
TIF file | PNG, CSV | Extract circularity, solidity, aspect ratio |
| shape_profiling | profile_shape_data() |
CSVs | PNG, CSV | Generate combined violin plots |
| tracking | track_organelles() |
TIF file | PNG, CSV, MP4 | Track organelle trajectories |
| tracking_overlay | track_overlay() |
TIF file | PNG, CSV, MP4 | Overlay tracks on intensity images |
| motility | analyze_motility() |
CSVs | PNG, CSV | Compute velocity and displacement |
| colocalization | analyze_colocalization() |
TIF file | PNG, CSV, MP4 | Quantify mitochondrial-lysosomal overlap |
| summary | summarize_integrated_data() |
CSVs | PNG, CSV | Correlation matrix across all metrics |
| validation | validate_segmentation() |
Masks | dict | Compute Dice, IoU, F1, precision, recall |
| validation | validate_tracking() |
CSVs | dict | Track accuracy metrics |
| validation | sensitivity_analysis() |
TIF + params | CSV, plots | Parameter sweep analysis |
| validation | generate_validation_report() |
Results | PNG, CSV | Comprehensive validation summary |
Output Files
| Step | Output Type | Example Files |
|---|---|---|
| Detection | PNG + MP4 | Mito_Frame0.png, Mitochondria_Detection.mp4 |
| Lysosome Count | PNG + CSV + MP4 | Lyso_Count_Plot.png, Lysosome_Counts.csv |
| Morphology | PNG + MP4 + CSV | Morphology_Frame0_Labeled.png, Morphology_Labeled.mp4 |
| Shape Features | PNG + CSV | Shape_Distributions.png, Mito_ShapeMetrics.csv |
| Shape Profiling | PNG + CSV | Shape_ViolinPlots.png, Combined_ShapeData.csv |
| Tracking | PNG + MP4 + CSV | Cumulative_Mito.png, Mito_Tracks.csv |
| Tracking Overlay | PNG + MP4 | Cumulative_Composite.png, Composite_CumulativeTracks.mp4 |
| Motility | PNG + CSV | Motility_Distributions.png, Motility_Scatter.png |
| Colocalization | PNG + MP4 + CSV | Colocalization_Frame0.png, Colocalization.csv |
| Summary | PNG + CSV | Integrated_CorrelationMatrix.png, Integrated_Merged_Data.csv |
| Validation | PNG + CSV | Validation_Report.png, Validation_Summary.csv |
Dependencies
Core Requirements:
- Python ≥ 3.9
- numpy ≥ 1.23.0
- pandas ≥ 1.5.0
- matplotlib ≥ 3.6.0
- seaborn ≥ 0.12.0
- opencv-python ≥ 4.6.0
- scikit-image ≥ 0.19.0
- scipy ≥ 1.9.0
- tifffile ≥ 2022.8.12
Optional:
- scikit-learn (for validation metrics)
Visualization Design
Colorblind-Safe Palette:
- Mitochondria:
#0173B2(blue) - Lysosomes:
#DE8F05(orange)
All visualizations use colorblind-safe colors to ensure accessibility and publication readiness.
Statistical Notes
Correlation Analysis (Summary Module): The integrated summary module uses Spearman rank correlation to compute relationships between extracted metrics, providing a distribution-free assessment of feature associations.
Comparison with Existing Tools
| Feature | AutoMorphoTrack | CellProfiler | MiNA | MitoGraph | Imaris |
|---|---|---|---|---|---|
| Ease of Use | High (Python API) | Medium (GUI-heavy) | Medium | Medium | Low (proprietary) |
| Transparency | Full (open source) | Partial | Partial | Partial | Closed |
| Lightweight | Yes | No | No | No | No |
| Publication-Ready Outputs | Yes | Yes | Partial | Partial | Yes |
| Tracking | Yes | Optional | Yes | Yes | Yes |
| Shape Profiling | Yes | Limited | Yes | Yes | Yes |
| Colocalization | Yes | Yes | Limited | Limited | Yes |
| Customizable | Yes (modular) | Yes | Limited | Limited | No |
| Cost | Free | Free | Free | Free | Expensive |
What Makes AutoMorphoTrack Different:
- Integrated workflow: All analyses in one package without external dependencies
- Full transparency: Complete source code and methodology documentation
- Lightweight: Minimal dependencies, fast execution
- Publication-ready: High-DPI outputs and colorblind-safe visualizations by default
- Modular design: Use only the modules you need
AI Assistance Note
This package was developed with support from AI language models (e.g., ChatGPT, Claude). The term "AI assistance" refers to using external LLMs to help generate, review, and refine analysis code—NOT a built-in AI interface or algorithmic component. All algorithms are explicit, interpretable, and scientifically grounded.
License
MIT License – See LICENSE.md for details.
Citation
If you use this pipeline in your work, please cite:
@article{bayati2025automorphotrack,
title={AutoMorphoTrack: Automated Organelle Tracking and Morphometric Profiling Toolkit},
author={Bayati, Armin and others},
year={2025}
}
Or in text:
Bayati, A. et al. AutoMorphoTrack: Automated Organelle Tracking and Morphometric Profiling Toolkit (2025)
Documentation
For detailed documentation, examples, and tutorials, visit:
- GitHub: github.com/abayatibrain/AutoMorphoTrack
- Issues & Support: github.com/abayatibrain/AutoMorphoTrack/issues
Author
Armin Bayati, Ph.D. Email: a.bayati.brain@gmail.com
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 automorphotrack-2.1.0.tar.gz.
File metadata
- Download URL: automorphotrack-2.1.0.tar.gz
- Upload date:
- Size: 30.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ada6099c97b61471363aafd778d84cf05fab3033b0e112855dd43a14afd5d07c
|
|
| MD5 |
c4d68671a9fb7366721666e6b5a5a2dd
|
|
| BLAKE2b-256 |
f0c459e3615c7fd1300db05078729e1cb0fed701823ad9c8b6289ea7f404cf3c
|
File details
Details for the file automorphotrack-2.1.0-py3-none-any.whl.
File metadata
- Download URL: automorphotrack-2.1.0-py3-none-any.whl
- Upload date:
- Size: 38.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e77aff65a2224a810b75788bab77079f0e710a76620b705d11b84e1da108b0a1
|
|
| MD5 |
fd505b217a22f0b7847de5715ff7a929
|
|
| BLAKE2b-256 |
6a358893c001ea8b5cea68e4c1755a0c11b6f113f2ddf3edc98f38b105b9829f
|