Skip to content

Commit fcf4bb9

Browse files
Jon PalmerJon Palmer
Jon Palmer
authored and
Jon Palmer
committed
update to v0.1.5
1 parent 061a808 commit fcf4bb9

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

bin/funannotate-predict.py

+8-6
Original file line numberDiff line numberDiff line change
@@ -193,14 +193,16 @@ def __init__(self,prog):
193193
#setup weights file for EVM
194194
Weights = os.path.join(args.out, 'predict_misc', 'weights.evm.txt')
195195
with open(Weights, 'w') as output:
196+
sources = []
197+
with open(Predictions, 'rU') as preds:
198+
for line in preds:
199+
source = line.split('\t')[1]
200+
if source not in sources:
201+
sources.append(source)
196202
if args.pasa_gff:
197203
output.write("OTHER_PREDICTION\ttransdecoder\t10\n")
198-
output.write("ABINITIO_PREDICTION\taugustus\t1\n")
199-
output.write("ABINITIO_PREDICTION\tgenemark\t1\n")
200-
else:
201-
output.write("ABINITIO_PREDICTION\taugustus\t1\n")
202-
output.write("ABINITIO_PREDICTION\tgenemark\t1\n")
203-
204+
for i in sources:
205+
output.write("ABINITIO_PREDICTION\t%s\t1\n" % i)
204206
output.write("PROTEIN\tprotein2genome\t1\n")
205207
output.write("TRANSCRIPT\test2genome\t1\n")
206208
Exonerate = os.path.abspath(Exonerate)

0 commit comments

Comments
 (0)