Skip to content

TractEdit v3.2.5

Choose a tag to compare

@marcotag93 marcotag93 released this 03 Jan 21:25

TractEdit v3.2.5 (January 3, 2026)

Linux Release

TractEdit is now available for Linux as standalone packages!
This release includes official AppImage and .deb package distributions with automatic display server detection—preferring native rendering and gracefully falling back to XCB when needed.


Key Features

  • Comprehensive Test Suite: Added a full pytest-based test suite with tox.ini configuration, covering 88 tests across the codebase to ensure stability and facilitate future development.
  • Startup Performance Optimization: Implemented cache=True for all Numba-decorated functions and added warmup_numba_functions() pre-compilation during app startup (displayed as "Optimizing performance..." on splash screen). This eliminates the ~1-3 second delay previously occurring on first file load, ensuring consistent loading times regardless of file size or load order.
  • Poetry for dependencies and build: Switched to Poetry and added a poetry-based lock file. Added a hook file for Pyinstaller to fix a Numpy ImportError during linux build.
  • Accelerated Medoid Calculation: Fixed freezing at 40% progress when processing large streamline bundles (50k+) by implementing an approximate medoid algorithm using random sampling. Reduces complexity from O(N²) to O(N×k), cutting distance calculations from 1.25 billion to 75 million and memory usage from 20GB to 600MB for 50k streamlines.
  • Optimized Selection Tools: Overhauled streamline selection and deletion performance for sphere tool (s and d shortcuts). Added SelectionManager caching to eliminate O(n log n) re-sorting, JIT-compiled parallel copying, incremental selection tracking via _last_selected_indices, and QTimer-based debouncing via schedule_highlight_update() to batch rapid selections into single actor rebuilds.
  • Batch Parallel Resampling: Added _resample_batch_numba function that processes all streamlines simultaneously using Numba prange, replacing the sequential Python loop for ~10-20x speedup during medoid resampling phase.
  • ODF Tunnel View: Added a new ODF tunnel visualization in the data panel, including right-click context menu options to show or hide it.
  • Interactive 2D Ruler: Added a zoom-based ruler overlay to all 2D panels for precise measurement reference.
  • Theme Support: Added a "Settings" menu with Light, Dark, and System theme options.

Minor Improvements

  • Added CLI option --load-roi to load a ROI file at application startup.
  • Added pre-import of nibabel.streamlines and trx.trx_file_memmap modules during splash screen to eliminate first-bundle loading delay.
  • Added cache=True to ROI intersection Numba function in roi_manager.py to prevent recompilation on every app restart.
  • Added warmup_selection_numba_functions() to pre-compile sphere/box selection Numba functions during startup.
  • Added invalidate_visible_cache() method to allow external callers to force cache rebuilds upon visibility changes.
  • Added PEP8-compliant comment blocks throughout the main sections of the codebase.
  • Added documentation comments regarding anatomical image flip corrections to enforce radiological convention over the neurological convention (VTK/Fury default).

Bug Fixes

  • Fixed a segmentation fault (core dump) on Linux occurring during application shutdown.
  • Fixed a bug related to loading uint8 or uint16 ROI data.
  • Fixed issues with very high-resolution (100µm) anatomical images and improved downsampling quality.
  • Fixed a bug preventing the reset of drawing modes after replacing an anatomical image.
  • Fixed a bug affecting sphere ROI drawing in the sagittal view.
  • Fixed a color change issue occurring when 3 is pressed without a loaded or drawn ROI image.
  • Fixed inverted Yes/No button placement in the "Close App" and "Replace Image" dialogs.