Skip to main content

Python toolkit for analyzing temporal dynamics of mitochondrial networks

Project description

Quick Start

MitoTNT is a Python toolkit for analyzing the temporal dynamics of mitochondrial networks.
It integrates with MitoGraph for per-frame segmentation, then performs tracking, remodeling event detection, motility analysis, and ChimeraX visualization.

This page walks through a typical workflow step by step.


1. Prepare your data

MitoTNT expects your raw time-lapse movie as a sequence of 3D image stacks (TIFF).
Each frame in time should be placed in its own folder, with a single .tif inside:

frame_000/frame_000.tif
frame_001/frame_001.tif
frame_002/frame_002.tif
...

This format makes it easy for MitoGraph to write outputs back into each frame’s folder.
Make sure you have MitoGraph installed and accessible in your PATH.


2. Segment mitochondria with MitoGraph

MitoGraph takes each 3D stack and generates:

  • Surface meshes .vtk for visualization.
  • Supporting .gnet, .coo, and .txt files describing network structure.

Run it through MitoTNT:

import mitotnt

seg = mitotnt.MitoSegmenter('D:/GitHub/MitoTNT/test_data/mitograph', 
                            xy_pxl_size=0.145, z_pxl_size=0.145) # add image pixel sizes in microns/pixel

seg.run_mitograph_cpu(max_workers=10) # specify the number of threads
  • xy_pxl_size and z_pxl_size are microns per pixel, important for scaling.
  • By default, results are saved inside each frame folder.

You can preview segmentation results in ChimeraX:

seg.visualize_segmented_data()

This generates a .cxc script for visual quality check of raw TIFFs alongside segmented surfaces.

3. Extract skeleton graphs

To prepare for tracking, you need to build graphs from MitoGraph outputs:

skel = mitotnt.SkeletonizedMito(seg)
skel.extract_graphs()

These graphs capture mitochondria location and connectivity and are the inputs to tracking.


4. Track mitochondrial networks

Tracking links network fragments across timepoints using both spatial and network information:

tracker = mitotnt.NetworkTracker(skel, frame_interval=3.3)  # frame interval in seconds per frame
tracked = tracker.run()
  • The algorithm maps nodes across frames, building trajectories for each mitochondrial fragment.
  • Results are written to: mitotnt/mito_node_tracks.csv (all node trajectories).

If you’ve already run once, reload results without recomputing to continue with the next sections:

tracked = tracker.reload_results()

You can also restrict tracking to a subset of frames, or skip frames (useful for slower processes or faster processing).

tracker = mitotnt.NetworkTracker(skel, frame_interval=3.3,
                                 start_frame=10, end_frame=30,
                                 tracking_interval=2)

5. Visualize in ChimeraX

MitoTNT can produce ready-to-load visualization scripts for UCSF ChimeraX:

viz = mitotnt.Visualizer(tracked)
viz.generate_chimerax_skeleton()  # skeleton structure
viz.generate_tracking_arrows()  # tracking arrows
viz.visualize_tracking()  # build full .cxc script

This creates a script:

mitotnt/visualization/visualize_tracking.cxc

Open it in ChimeraX to interactively explore:

  • Raw fluorescence cloud rendered for context.
  • Network skeletons across time.
  • Tracking arrows showing mitochondrial network movement.

6. Analyze remodeling and motility

Once tracking is complete, MitoTNT can quantify key mitochondrial behaviors:

# Detect network remodeling (fusion & fission events)
tracked.detect_fusion_fission()

# Compute motility at three levels:
# node (voxel), segment (linear branch), fragment (connected component)
tracked.compute_mitochondria_diffusivity() 

Each analysis writes a CSV file:

  • remodeling_events.csv → list of detected fusions/fissions.
  • node_diffusivity.csv, segment_diffusivity.csv, fragment_diffusivity.csv → quantitative mobility measures.

These files can be imported for downstream analyses and plotting.


Summary

  1. Organize your movie into per-frame 3D stacks.
  2. Run MitoGraph via MitoSegmenter to obtain skeletons.
  3. Extract graphs with SkeletonizedMito.
  4. Track fragments across frames using NetworkTracker.
  5. Visualize skeletons and dynamics in ChimeraX with Visualizer.
  6. Analyze remodeling events and motility with TrackedMito.

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

mitotnt-0.2.0.tar.gz (35.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mitotnt-0.2.0-py3-none-any.whl (35.4 kB view details)

Uploaded Python 3

File details

Details for the file mitotnt-0.2.0.tar.gz.

File metadata

  • Download URL: mitotnt-0.2.0.tar.gz
  • Upload date:
  • Size: 35.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.18

File hashes

Hashes for mitotnt-0.2.0.tar.gz
Algorithm Hash digest
SHA256 ca3f81fb13d2dbcbc206b17100bcd73e27f90680f4ed207a72d376f39299f585
MD5 a7c8736307a8ac6824badec79545fa4a
BLAKE2b-256 92e17db7aa15fae89c5f8a52487fcaf0ffed3c02094e44067d95fb9f15b24380

See more details on using hashes here.

File details

Details for the file mitotnt-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: mitotnt-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 35.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.18

File hashes

Hashes for mitotnt-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 94263b0e9fa801b1c8bb5871d6985047ea4bfc9800c5888129c5d1d02b940bfa
MD5 4b98cdab07cdfdc9223125e9473d692b
BLAKE2b-256 942040aba3418eb271c40ab7933c2271414bca7260e77c07903446bf4692adf0

See more details on using hashes here.

Supported by

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