CLI library to generate UCSC trackhubs from sequencing data
Project description
TrackNado 🌪️
TrackNado is a powerful Python library and CLI tool designed to rapidly generate complex UCSC Genome Browser track hubs. It handles the "heavy lifting" of metadata extraction, multi-dimensional groupings, and automated file conversion, letting you focus on the science.
🚀 Key Features
- Fluent Python API: A declarative
HubBuilderfor intuitive and reproducible hub construction. - Automated Conversion: Built-in, container-backed conversion for BED → bigBed and GTF/GFF → bigGenePred (with codon display).
- Custom Genomes (Assembly Hubs): Deep support for private assemblies with
.2bitintegration. - Multi-Dimensional Grouping: Seamlessly create SuperTracks, CompositeTracks (matrix display), and OverlayTracks.
- Universal Metadata: Extract metadata from filenames, parent directories, or external CSV/TSV tables.
- Smart Merging: Combine multiple projects into a single unified hub via sidecar JSON configurations.
- Type Safety: Fully validated by Pydantic and Pandera.
📦 Installation
pip install tracknado
TrackNado will automatically attempt to use UCSC tools from your $PATH. If not found, it can automatically pull and run them via Docker or Apptainer.
🛠️ Quick Start (CLI)
The CLI is powered by Typer and provides a modern, colorized experience with rich help strings.
1. Generate a Metadata Template
tracknado create --template tracks.csv
2. Create a Hub
tracknado create \
--metadata tracks.csv \
--output ./my_hub \
--genome-name hg38 \
--subgroup-by cell_type \
--subgroup-by assay \
--convert \
--chrom-sizes hg38.chrom.sizes
3. Create a Custom Assembly Hub
tracknado create \
-i tracks/*.bw \
--output ./custom_hub \
--custom-genome \
--twobit reference.2bit \
--organism "MySpecies"
🐍 Quick Start (Python API)
TrackNado’s fluent API makes complex hubs readable and maintainable.
import tracknado as tn
# Build a multi-dimensional hub with one statement
builder = (
tn.HubBuilder()
.add_tracks(['data/peaks.bed', 'data/signal.bw'])
.with_metadata_extractor(tn.from_seqnado_path)
.group_by('assay', as_supertrack=True) # Signal vs Peaks folders
.group_by('cell_type', 'condition') # Matrix display
.color_by('condition', palette='hls')
.with_convert_files()
.with_chrom_sizes("hg38.chrom.sizes")
)
# Build and Stage
hub = builder.build(
name="Scientific_Project",
genome="hg38",
outdir="hub_out/",
hub_email="scientist@lab.edu",
description_html="docs/project_summary.html"
)
hub.stage_hub()
🔍 Validation
Never host a broken hub again. TrackNado includes a built-in structural validator and support for the official UCSC hubCheck.
tracknado validate my_hub/
📖 Learn More
For full documentation, example metadata tables, and API references, visit: 👉 Documentation Portal
📄 License
TrackNado is released under the GNU General Public License v3.
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
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 tracknado-0.3.1.tar.gz.
File metadata
- Download URL: tracknado-0.3.1.tar.gz
- Upload date:
- Size: 1.3 MB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f91a50fc6b7031b5a1ce954195c5b0f56442ce838712ac83f07a1fe27395c678
|
|
| MD5 |
4040b9308c192b952e0ff51800782b90
|
|
| BLAKE2b-256 |
47cb17fc2124daec3501f4cd9d3d0b561f075eb7014c0b702df63282aaeb078c
|
Provenance
The following attestation bundles were made for tracknado-0.3.1.tar.gz:
Publisher:
python-publish.yml on alsmith151/TrackNado
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
tracknado-0.3.1.tar.gz -
Subject digest:
f91a50fc6b7031b5a1ce954195c5b0f56442ce838712ac83f07a1fe27395c678 - Sigstore transparency entry: 829258169
- Sigstore integration time:
-
Permalink:
alsmith151/TrackNado@6bfcd77cd6f204e3681a8f6980eb9a26607363c7 -
Branch / Tag:
refs/tags/v0.3.1 - Owner: https://github.com/alsmith151
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@6bfcd77cd6f204e3681a8f6980eb9a26607363c7 -
Trigger Event:
release
-
Statement type:
File details
Details for the file tracknado-0.3.1-py3-none-any.whl.
File metadata
- Download URL: tracknado-0.3.1-py3-none-any.whl
- Upload date:
- Size: 41.9 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 |
27d7866c75ddec13c5df1d9b0b0bf3d439c07a69b0a28002c35a493f732a6e1b
|
|
| MD5 |
afc8a8e2f39fb35bf2c91de66d857ffe
|
|
| BLAKE2b-256 |
a54088671092848025d3f3d809b35a4b5abe66684ace7f58569e39a07f82ae7f
|
Provenance
The following attestation bundles were made for tracknado-0.3.1-py3-none-any.whl:
Publisher:
python-publish.yml on alsmith151/TrackNado
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
tracknado-0.3.1-py3-none-any.whl -
Subject digest:
27d7866c75ddec13c5df1d9b0b0bf3d439c07a69b0a28002c35a493f732a6e1b - Sigstore transparency entry: 829258170
- Sigstore integration time:
-
Permalink:
alsmith151/TrackNado@6bfcd77cd6f204e3681a8f6980eb9a26607363c7 -
Branch / Tag:
refs/tags/v0.3.1 - Owner: https://github.com/alsmith151
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@6bfcd77cd6f204e3681a8f6980eb9a26607363c7 -
Trigger Event:
release
-
Statement type: