On the Python scripts
# hadge
l
On the Python scripts
PR: https://github.com/theislab/hadge/pull/67 Script 1: Basic Demultiplexing Merger Combines results from two demultiplexing approaches: • Input: Takes genetic and hashing demultiplexing output folders • Processing: Finds assignment and classification CSV files, merges them by barcode, and applies standard label mappings (DBL→doublet, AMB→negative, SNG→singlet) • Output: Creates merged assignment and classification files combining both approaches Script 2: Genetic Demultiplexing Pipeline Processes multiple genetic demultiplexing tools (Demuxlet, Freemuxlet, Vireo, Souporcell, scSplit): • Input: Each tool's output folder contains barcode assignments and method parameters • Processing: Each tool has a specific parser that extracts donor assignments and classifications from different file formats (.best files, .tsv files, etc.) • Data Integration: Optionally creates AnnData/MuData objects with the assignments for downstream analysis • Output: Individual tool results plus merged files combining all genetic methods Script 3: Hashing Demultiplexing Pipeline Processes hashtag antibody (HTO) demultiplexing results from multiple tools (demuxem, hashsolo, hashedDrops, multiseq, htodemux, GMM-Demux, BFF): • Input: Each tool produces different output formats (some with confidence scores, some with probability matrices) • Processing: Tool-specific parsers handle the varied output formats and map results to standard labels (singlet/doublet/negative) • Special Cases: Some tools like GMM-Demux require complex config file parsing to determine hashtag counts • Output: Similar to script 2 - individual results plus merged files
I'll gladly take any stones into my face for my LLM usage but it should be accurate in this case.
l
Thank you very much @Lukas Heumos! I'm currently implementing script 2 into our new pipeline. Then I would use the updated code in the PR as a reference now!
l
Yup!
💪 1
l
link to recent commit @Nico Trummer, is it fine to remove the argsparser and directly insert nextflow inputs with
"${variable}"
. I used the `.py`'s from
nf-core/modules
as a guide. None of them used flags like in a CLI interface.
Does anyone have an example file of
hash_summary/hashing_assignment_all.csv
or
hash_summary/hashing_classification_all.csv
for me?
Copy code
assignment_all.to_csv("hash_summary/hashing_assignment_all.csv", index=False)  
classification_all.to_csv("hash_summary/hashing_classification_all.csv", index=False)
from here: https://github.com/theislab/hadge/blob/feature/improve_python_scripts/bin/summary_hash.py
n
is it fine to remove the argsparser and directly insert nextflow inputs with
"${variable}"
.
Yes
Does anyone have an example file of
hash_summary/hashing_assignment_all.csv
or
hash_summary/hashing_classification_all.csv
for me?
This ZIP should contain everything you need
gratitude thank you 1