diff options
Diffstat (limited to 'workflows/pangenome-generate/relabel-seqs.py')
-rw-r--r-- | workflows/pangenome-generate/relabel-seqs.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/workflows/pangenome-generate/relabel-seqs.py b/workflows/pangenome-generate/relabel-seqs.py new file mode 100644 index 0000000..32f2386 --- /dev/null +++ b/workflows/pangenome-generate/relabel-seqs.py @@ -0,0 +1,13 @@ +import sys + +reads = $(inputs.readsFA) +subjects = $(inputs.subjects) + +for i, r in enumerate(reads): + with open(r["path"], "rt") as fa: + fa.readline() + print(">"+subjects[i]) + data = fa.read(8096) + while data: + sys.stdout.write(data) + data = fa.read(8096) |