Utilities for converting .trk tractography files into Neuroglancer precomputed annotation format, and serving them locally with HTTP requests.
Project description
trk_to_annotation
This repository provides utilities for converting .trk tractography files into Neuroglancer precomputed annotation format, and serving them locally with HTTP requests.
Install
python -m build
pip install .
Usage
python -m trk_to_annotation <trk_file> \
--annotation_output_dir ./precomputed_annotations \
--segmentation_output_dir ./precomputed_segmentations \
--grid_densities 1 2 4 8 16
Arguments
| Argument | Required | Default | Description |
|---|---|---|---|
| trk_file | ✅ | — | Path to the input .trk file |
| --annotation_output_dir | ❌ | ./precomputed_annotations | Output directory for precomputed annotations |
| --segmentation_output_dir | ❌ | ./precomputed_annotations/precomputed_segmentations | Output directory for precomputed segmentations |
| --grid_densities | ❌ | [1, 2, 4, 8, 16] | Grid densities (powers of two, ascending order) |
Running server for neuroglancer
Run the following command in the directory with your outputted folders
python -m trk_to_annotation.http_server
You should now be able to access the annotation and segmentation layers on neuroglancer via http://localhost:8000/
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 trk_to_annotation-0.0.2.tar.gz.
File metadata
- Download URL: trk_to_annotation-0.0.2.tar.gz
- Upload date:
- Size: 15.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7d8c55ec829580cfb37c8c7af9bea85aab2ca26eb5dda50be7aab712f82be9b3
|
|
| MD5 |
740b3bb421998e289b48401cb049281e
|
|
| BLAKE2b-256 |
290502dbe3512ea314752051644a71677a52aa011b21145c6baacf5db16efefc
|
Provenance
The following attestation bundles were made for trk_to_annotation-0.0.2.tar.gz:
Publisher:
publish.yml on lincbrain/trk_to_annotation
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
trk_to_annotation-0.0.2.tar.gz -
Subject digest:
7d8c55ec829580cfb37c8c7af9bea85aab2ca26eb5dda50be7aab712f82be9b3 - Sigstore transparency entry: 999905741
- Sigstore integration time:
-
Permalink:
lincbrain/trk_to_annotation@3f9d2d5aceb79f39031ed8d2a915dd1cf462f821 -
Branch / Tag:
refs/tags/0.0.2 - Owner: https://github.com/lincbrain
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@3f9d2d5aceb79f39031ed8d2a915dd1cf462f821 -
Trigger Event:
release
-
Statement type:
File details
Details for the file trk_to_annotation-0.0.2-py3-none-any.whl.
File metadata
- Download URL: trk_to_annotation-0.0.2-py3-none-any.whl
- Upload date:
- Size: 19.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
82d77bf898d8b3d7d63c2699e9fa9e582883fcbead0943136e548ee39cf6d142
|
|
| MD5 |
17930660f8d9d510705b99c61337bb12
|
|
| BLAKE2b-256 |
8e53df1835e2842f440c44dc79498c20b3cdfa45e78088233a61ab28c3842baf
|
Provenance
The following attestation bundles were made for trk_to_annotation-0.0.2-py3-none-any.whl:
Publisher:
publish.yml on lincbrain/trk_to_annotation
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
trk_to_annotation-0.0.2-py3-none-any.whl -
Subject digest:
82d77bf898d8b3d7d63c2699e9fa9e582883fcbead0943136e548ee39cf6d142 - Sigstore transparency entry: 999905785
- Sigstore integration time:
-
Permalink:
lincbrain/trk_to_annotation@3f9d2d5aceb79f39031ed8d2a915dd1cf462f821 -
Branch / Tag:
refs/tags/0.0.2 - Owner: https://github.com/lincbrain
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@3f9d2d5aceb79f39031ed8d2a915dd1cf462f821 -
Trigger Event:
release
-
Statement type: