Skip to main content

Tractometry Visualization Tool

Project description

trksnapshot

Installation

pip install trksnapshot (project page)

Description

trksnapshot is a CLI for creating bundle visualizations (created using FURY and DIPY). It supports

  1. Visualizing 3D bundles in an interactive window with custom color options and camera view. These include per-bundle color and along-tract color using BUAN (for tractometry results).
  2. Supports plotting bundle with glass brain and pial surfaces.
  3. Rotate the camera however you like and save camera settings to produce consistent plots.
  4. Save snapshot images for publication-ready figures!

All bundle visualizations in our recent work Microstructural mapping of neural pathways in Alzheimer's disease using macrostructure-informed normative tractometry were created with this script. Here's one of the figures:

bundle_atlas

Usage

[RECOMMENDED] To visualization bundle(s) with default pial surfaces (in MNI space)

trksnapshot \
      -i /path_to_tractogram/bundle*.trk \
      -glass default_pial \
      -show

You may also provide your own pial surface files

trksnapshot \
      -i /path_to_tractogram/bundle*.trk \
      -glass /path_to_surfaces/pial_left.nii /path_to_surfaces/pial_right.nii \
      -show

To visualization bundle(s) with default glass brain (must be in MNI space)

trksnapshot \
      -i /path_to_tractogram/bundle*.trk \
      -glass default_glass \
      -show

To visualization bundle with pial surfaces with BUAN output

trksnapshot \
      -i /path_to_tractogram/bundle.trk \
      -f /path_to_buan_results/pvals.npy \
      -ctitle pvalues -auto -cbar /path_to_output_folder/cbar.png \
      -glass /path_to_surfaces/pial_left.gii.gz /path_to_surfaces/pial_right.gii.gz
      -show \
      -o /path_to_output_folder/bundle.png

Citations

  1. Microstructural mapping of neural pathways in Alzheimer's disease using macrostructure-informed normative tractometry
  2. FURY: advanced scientific visualization

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

trksnapshot-0.1.3.tar.gz (8.1 kB view details)

Uploaded Source

Built Distribution

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

trksnapshot-0.1.3-py3-none-any.whl (8.0 kB view details)

Uploaded Python 3

File details

Details for the file trksnapshot-0.1.3.tar.gz.

File metadata

  • Download URL: trksnapshot-0.1.3.tar.gz
  • Upload date:
  • Size: 8.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.11

File hashes

Hashes for trksnapshot-0.1.3.tar.gz
Algorithm Hash digest
SHA256 b1e54a5d44716aa9f1a7354ae00f1414c2fe142623db6d761e560974c376ec4d
MD5 a72a553141e35a7076687f2a3d58b4d3
BLAKE2b-256 f96136fafc75605b9a58031481a311b4515bd909b3b1a88da0add1964e726a04

See more details on using hashes here.

File details

Details for the file trksnapshot-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: trksnapshot-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 8.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.11

File hashes

Hashes for trksnapshot-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 020795c689d82cc5258febe47a2a8b3056ce7a5d877a6cbb9e0f5a3d112e6515
MD5 208497c542015f16f2978b088a85a0e8
BLAKE2b-256 115121b3e744e190ea9dcae967186c12a397cc017e656e9a4cf137a0ed83e5e5

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