Skip to content

Commit 4298bc0

Browse files
author
Jon Palmer
committed
update to v0.3.6
1 parent de3f675 commit 4298bc0

File tree

3 files changed

+11
-7
lines changed

3 files changed

+11
-7
lines changed

bin/augustus_parallel.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def runAugustus(Input):
4949
else:
5050
chr = Input
5151
species='--species='+args.species
52-
hints_input = '--hintsfile='+os.path.join(tmpdir, chr+'.hints.gff')
52+
hints_input = '--hintsfile='+args.hints
5353
aug_out = os.path.join(tmpdir, Input+'.augustus.gff3')
5454
core_cmd = ['augustus', species, '--gff3=on', '--UTR=off', '--stopCodonExcludedFromCDS=False', os.path.join(tmpdir, chr+'.fa')]
5555
if args.hints:
@@ -101,6 +101,7 @@ def runAugustus(Input):
101101
with open(outputfile, 'w') as output:
102102
SeqIO.write(record, output, 'fasta')
103103

104+
'''
104105
#if hints file passed, split it up by scaffold
105106
if args.hints:
106107
for i in scaffolds:
@@ -113,6 +114,7 @@ def runAugustus(Input):
113114
cols = line.split('\t')
114115
if cols[0] == i:
115116
output.write(line)
117+
'''
116118

117119
#now loop through each scaffold running augustus
118120
if args.cpus > len(scaffolds):

bin/funannotate-predict.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -656,7 +656,9 @@ def __init__(self,prog):
656656
if not cols[0] in busco_complete:
657657
busco_complete[cols[0]] = cols[2]+':'+cols[3]+'-'+cols[4]
658658
start = int(cols[3]) - 100
659-
end = int(cols[4]) + 100
659+
if start < 1: #negative values no good for intersection
660+
start = 1
661+
end = int(cols[4]) + 100 #not sure if value is larger than contig if this will be problem for bedtools as well? If so will need to read in contig names and lengths into dictionary to check here.
660662
bedfile.write('%s\t%i\t%i\t%s\n' % (cols[2],start,end,cols[0]))
661663
#now get BUSCO GFF models
662664
busco_augustus_tmp = os.path.join(args.out, 'predict_misc', 'busco_augustus.tmp')
@@ -707,11 +709,11 @@ def __init__(self,prog):
707709
Busco_Predictions = os.path.abspath(busco_predictions)
708710
#parse entire EVM command to script
709711
if Exonerate and Transcripts:
710-
evm_cmd = [sys.executable, EVM_script, os.path.join(args.out, 'logfiles', 'funannotate-EVM_busco.log'), str(args.cpus), '--genome', MaskGenome, '--gene_predictions', Busco_Predictions, '--protein_alignments', Exonerate, '--transcript_alignments', Transcripts, '--weights', Busco_Weights, '--min_intron_length', str(args.min_intronlen), EVM_out]
712+
evm_cmd = [sys.executable, EVM_script, os.path.join(args.out, 'logfiles', 'funannotate-EVM_busco.log'), str(args.cpus), '--genome', MaskGenome, '--gene_predictions', Busco_Predictions, '--protein_alignments', busco_proteins, '--transcript_alignments', busco_transcripts, '--weights', Busco_Weights, '--min_intron_length', str(args.min_intronlen), EVM_out]
711713
elif not Exonerate and Transcripts:
712-
evm_cmd = [sys.executable, EVM_script, os.path.join(args.out, 'logfiles', 'funannotate-EVM_busco.log'),str(args.cpus), '--genome', MaskGenome, '--gene_predictions', Busco_Predictions, '--transcript_alignments', Transcripts, '--weights', Busco_Weights, '--min_intron_length', str(args.min_intronlen), EVM_out]
714+
evm_cmd = [sys.executable, EVM_script, os.path.join(args.out, 'logfiles', 'funannotate-EVM_busco.log'),str(args.cpus), '--genome', MaskGenome, '--gene_predictions', Busco_Predictions, '--transcript_alignments', busco_transcripts, '--weights', Busco_Weights, '--min_intron_length', str(args.min_intronlen), EVM_out]
713715
elif not Transcripts and Exonerate:
714-
evm_cmd = [sys.executable, EVM_script, os.path.join(args.out, 'logfiles', 'funannotate-EVM_busco.log'), str(args.cpus), '--genome', MaskGenome, '--gene_predictions', Busco_Predictions, '--protein_alignments', Exonerate, '--weights', Busco_Weights, '--min_intron_length', str(args.min_intronlen), EVM_out]
716+
evm_cmd = [sys.executable, EVM_script, os.path.join(args.out, 'logfiles', 'funannotate-EVM_busco.log'), str(args.cpus), '--genome', MaskGenome, '--gene_predictions', Busco_Predictions, '--protein_alignments', busco_proteins, '--weights', Busco_Weights, '--min_intron_length', str(args.min_intronlen), EVM_out]
715717
elif not any([Transcripts,Exonerate]):
716718
evm_cmd = [sys.executable, EVM_script, os.path.join(args.out, 'logfiles', 'funannotate-EVM_busco.log'), str(args.cpus), '--genome', MaskGenome, '--gene_predictions', Busco_Predictions, '--weights', Busco_Weights, '--min_intron_length', str(args.min_intronlen), EVM_out]
717719
#run EVM
@@ -782,7 +784,7 @@ def __init__(self,prog):
782784
gmc = 0
783785
lib.log.error("GeneMark predictions failed, proceeding with only Augustus")
784786

785-
#if hints used for Augustus, get high quality models > 80% coverage to pass to EVM
787+
#if hints used for Augustus, get high quality models > 90% coverage to pass to EVM
786788
if os.path.isfile(hints_all) and not args.rna_bam:
787789
lib.log.info("Pulling out high quality Augustus predictions")
788790
hiQ_models = []

funannotate.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def fmtcols(mylist, cols):
3131
for i in range(0,num_lines))
3232
return "\n".join(lines)
3333

34-
version = '0.3.5'
34+
version = '0.3.6'
3535

3636
default_help = """
3737
Usage: funannotate <command> <arguments>

0 commit comments

Comments
 (0)