projects
/
htsworkflow.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
e3cd2ac
)
we might as well automatically save the Summary.htm file as well
author
Diane Trout
<diane@caltech.edu>
Thu, 14 Aug 2008 00:09:39 +0000
(
00:09
+0000)
committer
Diane Trout
<diane@caltech.edu>
Thu, 14 Aug 2008 00:09:39 +0000
(
00:09
+0000)
gaworkflow/pipeline/runfolder.py
patch
|
blob
|
history
diff --git
a/gaworkflow/pipeline/runfolder.py
b/gaworkflow/pipeline/runfolder.py
index 3758679a97ca05956617d0c2aef0fee6611bd540..b72194cce093f38945d7d55750d516bc0b66cb44 100644
(file)
--- a/
gaworkflow/pipeline/runfolder.py
+++ b/
gaworkflow/pipeline/runfolder.py
@@
-5,6
+5,7
@@
from glob import glob
import logging
import os
import re
import logging
import os
import re
+import shutil
import stat
import subprocess
import sys
import stat
import subprocess
import sys
@@
-210,8
+211,13
@@
def summary_report(runs):
report.append("Clusters %d +/- %d" % (cluster[0], cluster[1]))
report.append("Total Reads: %d" % (result.reads))
mc = result._match_codes
report.append("Clusters %d +/- %d" % (cluster[0], cluster[1]))
report.append("Total Reads: %d" % (result.reads))
mc = result._match_codes
- report.append("No Match: %d" % (mc['NM']))
- report.append("QC Failed: %d" % (mc['QC']))
+ nm = mc['NM']
+ nm_percent = float(nm)/result.reads * 100
+ qc = mc['QC']
+ qc_percent = float(qc)/result.reads * 100
+
+ report.append("No Match: %d (%2.2g %%)" % (nm, nm_percent))
+ report.append("QC Failed: %d (%2.2g %%)" % (qc, qc_percent))
report.append('Unique (0,1,2 mismatches) %d %d %d' % \
(mc['U0'], mc['U1'], mc['U2']))
report.append('Repeat (0,1,2 mismatches) %d %d %d' % \
report.append('Unique (0,1,2 mismatches) %d %d %d' % \
(mc['U0'], mc['U1'], mc['U2']))
report.append('Repeat (0,1,2 mismatches) %d %d %d' % \
@@
-250,6
+256,14
@@
def extract_results(runs, output_base_dir=None):
# save run file
r.save(cycle_dir)
# save run file
r.save(cycle_dir)
+ # Copy Summary.htm
+ summary_path = os.path.join(r.gerald.pathname, 'Summary.htm')
+ if os.path.exists(summary_path):
+ logging.info('Copying %s to %s' % (summary_path, cycle_dir))
+ shutil.copy(summary_path, cycle_dir)
+ else:
+ logging.info('Summary file %s was not found' % (summary_path,))
+
# tar score files
score_files = []
for f in os.listdir(g.pathname):
# tar score files
score_files = []
for f in os.listdir(g.pathname):