diff options
Diffstat (limited to 'workflows/pangenome-generate/dups2metadata.py')
-rw-r--r-- | workflows/pangenome-generate/dups2metadata.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/workflows/pangenome-generate/dups2metadata.py b/workflows/pangenome-generate/dups2metadata.py index 9bda10a..89e7236 100644 --- a/workflows/pangenome-generate/dups2metadata.py +++ b/workflows/pangenome-generate/dups2metadata.py @@ -1,17 +1,16 @@ import sys +import re md = open(sys.argv[1], "rt") for d in md: - print(d) + sys.stdout.write(d) if len(sys.argv) < 3: exit(0) sameseqs = open(sys.argv[2], "rt") for d in sameseqs: - logging.warn(d) g = re.match(r"\d+\t(.*)", d) - logging.warn("%s", g.group(1)) sp = g.group(1).split(",") for n in sp[1:]: - print("<%s> <http://biohackathon.org/bh20-seq-schema/has_duplicate_sequence> <%s> ." % (n.strip(), sp[0].strip())) + sys.stdout.write("<%s> <http://biohackathon.org/bh20-seq-schema/has_duplicate_sequence> <%s> .\n" % (n.strip(), sp[0].strip())) |