trait2d

TRAIT2D is a cross-platform Python software package with compilable graphical user interfaces (GUIs) to support Single Particle Tracking experiments.

https://github.com/eggeling-lab-microscope-software/trait2d

Science Score: 77.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 2 DOI reference(s) in README
  • Academic publication links
    Links to: zenodo.org
  • Committers with academic emails
    3 of 9 committers (33.3%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (16.1%) to scientific vocabulary
Last synced: 6 months ago · JSON representation ·

Repository

TRAIT2D is a cross-platform Python software package with compilable graphical user interfaces (GUIs) to support Single Particle Tracking experiments.

Basic Info
  • Host: GitHub
  • Owner: Eggeling-Lab-Microscope-Software
  • License: gpl-3.0
  • Language: Python
  • Default Branch: master
  • Homepage:
  • Size: 77.2 MB
Statistics
  • Stars: 10
  • Watchers: 4
  • Forks: 10
  • Open Issues: 6
  • Releases: 6
Created almost 7 years ago · Last pushed over 2 years ago
Metadata Files
Readme Contributing License Citation

README.md

TRAIT2D

PyPI PyPI - Wheel PyPI - Python Version PyPI - License DOI

Tests

TRAIT2D (available as trait2d) is a cross-platform Python software package with compilable graphical user interfaces (GUIs) to support Single Particle Tracking experiments. The software can be divided, in three main sections: the tracker, the simulator and the data analyzer.

The documentation is available at GitHub Pages.

Further information on the tool, together with more extensive theoretical foundations, is available on the related F1000Research Article.

Citing Information

Reina F, Wigg JMA, Dmitrieva M et al. TRAIT2D: a Software for Quantitative Analysis of Single Particle Diffusion Data [version 1; peer review: 1 approved, 1 approved with reservations]. F1000Research 2021, 10:838 (https://doi.org/10.12688/f1000research.54788.1)

Features

  • SPT simulation, tracking and analysis
  • user-friendly GUIs for simple tasks
  • customisable libraries for more advanced users
  • open source under the GNU General Public License

Contributing

Guidelines for contributing to the project can be found here.

Installation

Installation methods have been tested on Linux and Windows.

Install from PyPI (Recommended)

Prerequisites:

  • A Python installation (version >= 3.7 is required)

Installation:

  • run pip install trait2d

Install from Source (Not Recommended)

Prerequisites:

  • A Python installation (version >= 3.7 is required)
  • Optional: A Git installation

Installation:

  • clone the GitHub repository

    • run git clone https://github.com/Eggeling-Lab-Microscope-Software/TRAIT2D
    • OR
      • visit https://github.com/Eggeling-Lab-Microscope-Software/TRAIT2D
      • click the green Code button and then Download ZIP
      • extract the downloaded .zip file anywhere on your computer
  • change to the directory that was just created (should contain a setup.py file)

  • run pip install -e .

Quickstart

GUIs

There are GUIs available for simple simulation, tracking and analysis tasks.

To start using them follow these steps:

  • open a terminal
  • if you installed the package with conda to a separate environment, activate it (e.g. conda activate trait2d)
  • type trait2d_analysis_gui, trait2d_simulator_gui or trait2d_tracker_gui and hit enter

Library Modules

To use the trait2d modules, you can import them in your Python scripts or notebooks.

The simulator module is available as trait2d.simulators and the analysis module as trait2d.analysis.

For more information, check the documentation on the simulation and analysis libraries.

Examples are available in the gallery.

Further GUI Usage

You can find more information and GUI descriptions in the documentation on the analysis, simulator, and tracker GUIs.

Detection and Tracking

  • Launch a terminal (or the Anaconda Prompt on Windows)
  • if neccessary, activate the environment (e.g. conda activate trait2d)
  • run trait2d_tracker_gui

Setting parameters:

Use “Preview” button to evaluate performance of the detector. It shows detections for the current frame.

Parameters:
* SEF: sigma – parameters of the Laplacian-of-Gaussian(LoG) kernel. It relates to the spot size (increase to detect larger particles) * SEF: threshold – parameter for the image threshold after LoG. It relates to the intensity of the spots (decrease to detect particles with lower intensity) * SEF: min peak value – parameter of the detected peak size. It relates to the intensity of the spots (decrease to detect particles with lower intensity) * patch size – size of the region of interest with the particle (should be bigger than expected particle size). It can influence the particle localisation accuracy.
* Linking: max distance – maximum possible distance (in pixels) between detections to be linked (increase to link detections located further away from each other) * Linking: frame gap – maximum possible number of frames between detections to be linked (increase if the final trajectory is broken into parts) * Minimum track length – helps to eliminate short tracks created by false detections * resolution - set the value to get trajectories in mircons * frame rate - set the value to get timescale of the trajectories in seconds

Proposed workflow:

1) choose timelapse tiff sequence and run pre-processing step if necessary 2) choose between dark or light spots 3) tune detection parameters to detect all the particles. It is recommended to test the results for a few different frames using "Preview" button 4) set resolution and frame rate (optional) 5) set linking parameters 6) run linking by pressing "Run tracking" button. It will run linking algorithm and offer to save tiff file with plotted trajectories. Check the trajectories and change the linking parameters if needed. Use minimum track length parameter to eliminate short tracks 7) when the tracks provided by the tracker is good enough - save csv file with the particle trajectories (button “Save data”)

Advice:
  • If the final trajectory is broken into parts - it means, that the detection is failing in a sequence of frames. Firstly, the detection settings can be tuned to detect particles in the sequence, secondly the frame gap can be increased to connect the detection after the sequence of lost detections.

Movie simulation: command line

  • Launch a terminal (or the Anaconda Prompt on Windows)
  • Activate the environment with: conda activate iscat
  • Go to the source directory
  • Run the simulation python scripts/simulate_iscat_movie.py /path/to/track.csv /path/to/output.tif --psf /path/to/psf.tif --gaussian_noise --poisson_noise
    • tracks.csv is a file containing the tracks to reconstruct
    • The optional psf.tif file is a 3D PSF stack were the middle slice is in focus.
    • The PSF can be generated with the ImageJ plugin DeconvolutionLab2
    • Other simulation options can be listed with: python scripts/simulate_iscat_movie.py --help

Movie Simulation: GUI

  • Launch a terminal (or the Anaconda Prompt on Windows)
  • If neccessary activate the environment (e.g. conda activate trait2d)
  • run trait2d_simulator_gui
  • Generate/load trajectory first, then generate the image sequence and save it

Simulated track and iscat movie example. (Left) Raw image, (Right) convolved with a synthetic PSF.

Owner

  • Name: Eggeling-Lab-Microscope-Software
  • Login: Eggeling-Lab-Microscope-Software
  • Kind: organization

Citation (CITATION.cff)

cff-version: 1.2.0
message: "If you use this software, please cite it as below."
authors:
- family-names: "Reina"
  given-names: "Francesco"
  orcid: "https://orcid.org/0000-0001-6752-9089"
- family-names: "Wigg"
  given-names: "John Maxwell Andreas"
- family-names: "Dmitrieva"
  given-names: "Mariia"
- family-names: "Vogler"
  given-names: "Bela"
- family-names: "Lefebvre"
  given-names: "Joёl"
- family-names: "Rittscher"
  given-names: "Jens"
- family-names: "Eggeling"
  given-names: "Christian"
title: "TRAIT2D: a Software for Quantitative Analysis of Single Particle Diffusion Data"
doi: 10.5281/zenodo.4725268
date-released: 2021-06-21
url: "https://github.com/Eggeling-Lab-Microscope-Software/TRAIT2D"

GitHub Events

Total
Last Year

Committers

Last synced: almost 3 years ago

All Time
  • Total Commits: 538
  • Total Committers: 9
  • Avg Commits per committer: 59.778
  • Development Distribution Score (DDS): 0.31
Top Committers
Name Email Commits
John Wigg j****g@u****e 371
MariiaVision m****a@g****m 75
joe-from-mtl j****e@g****m 30
CaptainProton42 j****g@g****t 22
FReina f****3@g****m 19
Joel Lefebvre j****e@e****k 10
Joël Lefebvre l****l@u****a 6
Bela Vogler b****r@u****e 3
Bela Vogler v****a@t****e 2
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 7 months ago

All Time
  • Total issues: 42
  • Total pull requests: 35
  • Average time to close issues: 6 months
  • Average time to close pull requests: 6 days
  • Total issue authors: 5
  • Total pull request authors: 6
  • Average comments per issue: 1.9
  • Average comments per pull request: 0.49
  • Merged pull requests: 28
  • Bot issues: 0
  • Bot pull requests: 3
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • FReina (23)
  • john-wigg (9)
  • joe-from-mtl (5)
  • Zatyrus (3)
  • MariiaVision (2)
Pull Request Authors
  • john-wigg (18)
  • FReina (6)
  • dependabot[bot] (3)
  • MariiaVision (3)
  • joe-from-mtl (3)
  • Zatyrus (2)
Top Labels
Issue Labels
enhancement (10) bug (7) typo (2) documentation (2) fixed on fork (2)
Pull Request Labels
dependencies (3) enhancement (2)

Dependencies

setup.py pypi
  • PyQt5 *
  • imageio *
  • matplotlib *
  • numpy *
  • opencv-python *
  • pandas *
  • pyqtgraph *
  • scikit-image *
  • scipy *
  • setuptools *
  • tk *
  • tqdm *
  • wheel *
sphinx/requirements.txt pypi
  • docutils ==0.12
  • imageio ==2.9.0
  • matplotlib ==3.3.2
  • numpy ==1.19.3
  • pandas ==1.1.3
  • scikit-image ==0.17.2
  • scipy ==1.5.3
  • sphinx ==3.2.1
  • sphinx-gallery ==0.8.1
  • sphinx_rtd_theme ==0.5.0
  • tqdm ==2.2.3