[med-svn] [Git][med-team/kma][master] 5 commits: Add autopkgtests
Nilesh Patra
gitlab at salsa.debian.org
Sun Oct 4 12:33:47 BST 2020
Nilesh Patra pushed to branch master at Debian Med / kma
Commits:
c9ac6ade by Nilesh Patra at 2020-10-04T17:00:23+05:30
Add autopkgtests
- - - - -
aa5d2915 by Nilesh Patra at 2020-10-04T17:00:56+05:30
routine-update: New upstream version
- - - - -
5f0f3327 by Nilesh Patra at 2020-10-04T17:00:57+05:30
New upstream version 1.3.4
- - - - -
43cb3464 by Nilesh Patra at 2020-10-04T17:00:58+05:30
Update upstream source from tag 'upstream/1.3.4'
Update to upstream version '1.3.4'
with Debian dir 16cbda4e7e224cec412a329915e00f9a0d1a6dd4
- - - - -
e171acaf by Nilesh Patra at 2020-10-04T17:03:29+05:30
Update changelog
- - - - -
13 changed files:
- Makefile
- + db.c
- + db.h
- debian/changelog
- + debian/tests/control
- + debian/tests/run-unit-test
- kma.c
- main.c
- mt1.c
- printconsensus.c
- runkma.c
- spltdb.c
- version.h
Changes:
=====================================
Makefile
=====================================
@@ -1,6 +1,6 @@
CFLAGS ?= -Wall -O3
CFLAGS += -std=c99
-LIBS = align.o alnfrags.o ankers.o assembly.o chain.o compdna.o compkmers.o compress.o decon.o dist.o ef.o filebuff.o frags.o hashmap.o hashmapcci.o hashmapkma.o hashmapkmers.o hashtable.o index.o kma.o kmapipe.o kmeranker.o kmers.o kmmap.o loadupdate.o makeindex.o matrix.o mt1.o nw.o pherror.o printconsensus.o qseqs.o qualcheck.o runinput.o runkma.o sam.o savekmers.o seq2fasta.o seqmenttree.o seqparse.o shm.o sparse.o spltdb.o stdnuc.o stdstat.o tmp.o update.o updateindex.o updatescores.o valueshash.o vcf.o xml.o
+LIBS = align.o alnfrags.o ankers.o assembly.o chain.o compdna.o compkmers.o compress.o db.o decon.o dist.o ef.o filebuff.o frags.o hashmap.o hashmapcci.o hashmapkma.o hashmapkmers.o hashtable.o index.o kma.o kmapipe.o kmeranker.o kmers.o kmmap.o loadupdate.o makeindex.o matrix.o mt1.o nw.o pherror.o printconsensus.o qseqs.o qualcheck.o runinput.o runkma.o sam.o savekmers.o seq2fasta.o seqmenttree.o seqparse.o shm.o sparse.o spltdb.o stdnuc.o stdstat.o tmp.o update.o updateindex.o updatescores.o valueshash.o vcf.o xml.o
PROGS = kma kma_index kma_shm kma_update
.c .o:
@@ -34,6 +34,7 @@ chain.o: chain.h penalties.h pherror.h stdstat.h
compdna.o: compdna.h pherror.h stdnuc.h
compkmers.o: compkmers.h pherror.h
compress.o: compress.h hashmap.h hashmapkma.h pherror.h valueshash.h
+db.o: db.h hashmapkma.h pherror.h stdstat.h
decon.o: decon.h compdna.h filebuff.h hashmapkma.h seqparse.h stdnuc.h qseqs.h updateindex.h
dist.o: dist.h hashmapkma.h matrix.h pherror.h
ef.o: ef.h assembly.h stdnuc.h vcf.h version.h
=====================================
db.c
=====================================
@@ -0,0 +1,216 @@
+/* Philip T.L.C. Clausen Jan 2017 plan at dtu.dk */
+
+/*
+ * Copyright (c) 2017, Philip Clausen, Technical University of Denmark
+ * All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+*/
+#define _XOPEN_SOURCE 600
+#include <limits.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include "db.h"
+#include "hashmapkma.h"
+#include "pherror.h"
+#include "stdstat.h"
+
+void dbInfo(char *filename) {
+
+ const char bases[6] = "ACGTN-";
+ int i, filename_len, min, max, index;
+ unsigned *values, *value_index;
+ short unsigned *values_s;
+ long unsigned ntcount, prefix, ntax, v_index, n, size;
+ long unsigned *value_index_l;
+ double mean, var, tmp;
+ char Prefix[33];
+ FILE *dbfile;
+ HashMapKMA *templates;
+
+ /* print DB name */
+ fprintf(stdout, "DB:\t%s\n", filename);
+
+ /* get # nucleotides */
+ filename_len = strlen(filename);
+ strcpy(filename + filename_len, ".seq.b");
+ dbfile = sfopen(filename, "rb");
+ fseek(dbfile, 0, SEEK_END);
+ ntcount = 4 * ftell(dbfile);
+ fclose(dbfile);
+ filename[filename_len] = 0;
+ fprintf(stdout, "# nucleotides:\t%lu\n", ntcount);
+
+ /* load database */
+ strcpy(filename + filename_len, ".comp.b");
+ dbfile = sfopen(filename, "rb" );
+ templates = smalloc(sizeof(HashMapKMA));
+ if(hashMapKMA_load(templates, dbfile, filename) == 1) {
+ fprintf(stderr, "Wrong format of DB.\n");
+ exit(1);
+ }
+ fclose(dbfile);
+ filename[filename_len] = 0;
+
+ /* get basic statistics */
+ fprintf(stdout, "# templates:\t%d\n", templates->DB_size);
+ fprintf(stdout, "k:\t%d\n", templates->kmersize);
+ /* get prefix */
+ if(templates->prefix_len) {
+ prefix = templates->prefix;
+ i = templates->prefix_len;
+ Prefix[i] = 0;
+ while(i--) {
+ Prefix[i] = bases[prefix & 3];
+ prefix >>= 2;
+ }
+ fprintf(stderr, "prefix:\t%s\n", Prefix);
+ } else if(templates->prefix != 0) {
+ fprintf(stderr, "prefix:\t-\n");
+ }
+ fprintf(stdout, "# uniq k-mers:\t%lu\n", templates->n);
+ fprintf(stdout, "k-mer fraqtion covered:\t%f\n", templates->n / power(4, templates->kmersize));
+ fprintf(stdout, "inferred tax size:\t%lu\n", templates->v_index);
+
+ /* get number of unique inferred tax */
+ ntax = 0;
+ v_index = templates->v_index;
+ if(templates->DB_size < USHRT_MAX) {
+ values_s = templates->values_s;
+ while(v_index) {
+ ++ntax;
+ i = *values_s + 1;
+ v_index -= i;
+ values_s += i;
+ }
+ } else {
+ values = templates->values;
+ while(v_index) {
+ ++ntax;
+ i = *values + 1;
+ v_index -= i;
+ values += i;
+ }
+ }
+ fprintf(stderr, "# inferred taxids:\t%lu\n", ntax);
+
+ /* get min, max, mean and variance of k-mer uniqueness */
+ if((templates->size - 1) == templates->mask) {
+ if(templates->v_index <= UINT_MAX) {
+ value_index = templates->exist;
+ value_index_l = 0;
+ } else {
+ value_index = 0;
+ value_index_l = templates->exist_l;
+ }
+ } else {
+ if(templates->n <= UINT_MAX) {
+ value_index = templates->value_index;
+ value_index_l = 0;
+ } else {
+ value_index = 0;
+ value_index_l = templates->value_index_l;
+ }
+ }
+ if(templates->DB_size < USHRT_MAX) {
+ values = 0;
+ values_s = templates->values_s;
+ } else {
+ values = templates->values;
+ values_s = 0;
+ }
+ n = templates->n;
+ size = n;
+ min = templates->DB_size;
+ max = 1;
+ mean = 0;
+ var = 0;
+ while(size) {
+ index = value_index ? *value_index++ : *value_index_l++;
+ if(index != 1) {
+ index = values ? values[index] : values_s[index];
+ if(index < min) {
+ min = index;
+ }
+ if(max < index) {
+ max = index;
+ }
+ mean += index;
+
+ /* avoid overflow on var */
+ tmp = index * index;
+ tmp /= n;
+ var += tmp;
+
+ --size;
+ }
+ }
+ mean /= n;
+ var -= mean * mean;
+
+ fprintf(stderr, "k-mer co-occurence var:\t%f\n", var);
+ fprintf(stderr, "k-mer co-occurence mean:\t%f\n", mean);
+ fprintf(stderr, "k-mer co-occurence min:\t%d\n", min);
+ fprintf(stderr, "k-mer co-occurence max:\t%d\n", max);
+}
+
+static void helpMessage(int exeStatus) {
+ FILE *helpOut;
+ if(exeStatus == 0) {
+ helpOut = stdout;
+ } else {
+ helpOut = stderr;
+ }
+ fprintf(helpOut, "# KMA db gives statistics on a KMA database\n");
+ fprintf(helpOut, "# Options are:\t\tDesc:\t\t\t\t\tRequirements:\n");
+ fprintf(helpOut, "#\n");
+ fprintf(helpOut, "#\t-t_db\t\tTemplate DB\t\t\t\tREQUIRED\n");
+ fprintf(helpOut, "#\t-h\t\tShows this help message\n");
+ fprintf(helpOut, "#\n");
+ exit(exeStatus);
+}
+
+int db_main(int argc, char *argv[]) {
+
+ unsigned args;
+ char *filename;
+
+ /* set defaults */
+ filename = 0;
+ args = 1;
+ while(args < argc) {
+ if(strcmp(argv[args], "-t_db") == 0) {
+ if(++args < argc) {
+ filename = smalloc(strlen(argv[args]) + 64);
+ strcpy(filename, argv[args]);
+ }
+ } else if(strcmp(argv[args], "-h") == 0) {
+ helpMessage(0);
+ } else {
+ fprintf(stderr, " Invalid option:\t%s\n", argv[args]);
+ fprintf(stderr, " Printing help message:\n");
+ helpMessage(1);
+ }
+ ++args;
+ }
+
+ if(!filename) {
+ fprintf(stderr, "Insuffient amount of arguments handed!!!\n");
+ helpMessage(1);
+ }
+
+ dbInfo(filename);
+
+ return 0;
+}
=====================================
db.h
=====================================
@@ -0,0 +1,21 @@
+/* Philip T.L.C. Clausen Jan 2017 plan at dtu.dk */
+
+/*
+ * Copyright (c) 2017, Philip Clausen, Technical University of Denmark
+ * All rights reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+*/
+
+void dbInfo(char *filename);
+int db_main(int argc, char *argv[]);
=====================================
debian/changelog
=====================================
@@ -1,3 +1,11 @@
+kma (1.3.4-1) unstable; urgency=medium
+
+ * Team upload.
+ * New upstream version
+ * Add autopkgtests
+
+ -- Nilesh Patra <npatra974 at gmail.com> Sun, 04 Oct 2020 17:01:08 +0530
+
kma (1.3.3-1) unstable; urgency=medium
* Team upload.
=====================================
debian/tests/control
=====================================
@@ -0,0 +1,4 @@
+Tests: run-unit-test
+Depends: @
+Restrictions: allow-stderr
+
=====================================
debian/tests/run-unit-test
=====================================
@@ -0,0 +1,26 @@
+#!/bin/bash
+set -e
+
+CUR_DIR=`pwd`
+export LC_ALL=C.UTF-8
+if [ "${AUTOPKGTEST_TMP}" = "" ] ; then
+ AUTOPKGTEST_TMP=$(mktemp -d /tmp/${pkg}-test.XXXXXX)
+ trap "rm -rf ${AUTOPKGTEST_TMP}" 0 INT QUIT ABRT PIPE TERM
+fi
+
+cd "${AUTOPKGTEST_TMP}"
+cp ${CUR_DIR}/performanceAndComparisonCMDs.tar.gz .
+tar -xzvf *.tar.gz
+cd benchmarkCMDs
+
+echo "Simple test to check indexing function"
+kma index -i ResFinder.fasta -o ResFinder
+for f in ResFinder.*
+do
+ [ -s $f ] || exit 1
+done
+
+echo "Clean up ..."
+cd ..
+rm -rf benchmarkCMDs/ *.tar.gz
+echo "PASS"
=====================================
kma.c
=====================================
@@ -123,11 +123,12 @@ static void helpMessage(int exeStatus) {
fprintf(helpOut, "#\t-vcf\t\tMake vcf file, 2 to apply FT\tFalse/0\n");
fprintf(helpOut, "#\t-sam\t\tOutput sam to stdout, 4 to \n#\t\t\tonly output mapped reads, \n#\t\t\t2096 for aligned\t\tFalse/0\n");
fprintf(helpOut, "#\t-nc\t\tNo consensus file\t\tFalse\n");
+ fprintf(helpOut, "#\t-na\t\tNo aln file\t\tFalse\n");
fprintf(helpOut, "#\t-nf\t\tNo frag file\t\t\tFalse\n");
fprintf(helpOut, "#\t-deCon\t\tRemove contamination\t\tFalse\n");
fprintf(helpOut, "#\t-dense\t\tDo not allow insertions\n#\t\t\tin assembly\t\t\tFalse\n");
fprintf(helpOut, "#\t-sasm\t\tSkip alignment and assembly\tFalse\n");
- fprintf(helpOut, "#\t-ref_fsa\tConsensus sequnce will\n#\t\t\thave \"n\" instead of gaps\tFalse\n");
+ fprintf(helpOut, "#\t-ref_fsa\tConsensus sequnce will\n#\t\t\thave \"n\" instead of gaps\tFalse / 0\n");
fprintf(helpOut, "#\t-matrix\t\tPrint assembly matrix\t\tFalse\n");
fprintf(helpOut, "#\t-a\t\tPrint all best mappings\t\tFalse\n");
fprintf(helpOut, "#\t-mp\t\tMinimum phred score\t\t20\n");
@@ -162,7 +163,7 @@ static void helpMessage(int exeStatus) {
fprintf(helpOut, "#\t-gapopen\tPenalty for gap opening\t\t-3\n");
fprintf(helpOut, "#\t-gapextend\tPenalty for gap extension\t-1\n");
fprintf(helpOut, "#\t-per\t\tReward for pairing reads\t7\n");
- fprintf(helpOut, "#\t-localopen\t\tPenalty for openning a local chain\t-6\n");
+ fprintf(helpOut, "#\t-localopen\tPenalty for openning a local chain\t-6\n");
fprintf(helpOut, "#\t-Npenalty\tPenalty matching N\t\t0\n");
fprintf(helpOut, "#\t-transition\tPenalty for transition\t\t-2\n");
fprintf(helpOut, "#\t-transversion\tPenalty for transversion\t-2\n");
@@ -535,6 +536,17 @@ int kma_main(int argc, char *argv[]) {
print_all = 1;
} else if(strcmp(argv[args], "-ref_fsa") == 0) {
ref_fsa = 1;
+ if(++args < argc && *(argv[args]) != '-') {
+ ref_fsa = strtoul(argv[args], &exeBasic, 10);
+ if(*exeBasic != 0) {
+ fprintf(stderr, "Invalid argument at \"-3p\".\n");
+ exit(4);
+ } else if(ref_fsa == 0) {
+ ref_fsa = 2;
+ }
+ } else {
+ --args;
+ }
} else if(strcmp(argv[args], "-Sparse") == 0) {
sparse_run = 1;
} else if(strcmp(argv[args], "-1t1") == 0) {
@@ -551,7 +563,7 @@ int kma_main(int argc, char *argv[]) {
if(*exeBasic != 0 || support < 0 || 1 < support) {
fprintf(stderr, "Invalid argument at \"-proxi\".\n");
exit(1);
- } if(support != 1) {
+ } else {
/* set proximity parameter */
getMatch = &getProxiMatch;
getMatchSparse = &getProxiMatchSparse;
@@ -815,6 +827,8 @@ int kma_main(int argc, char *argv[]) {
}
} else if(strcmp(argv[args], "-nc") == 0) {
nc = 1;
+ } else if(strcmp(argv[args], "-na") == 0) {
+ nc = 2;
} else if(strcmp(argv[args], "-nf") == 0) {
nf = 1;
} else if(strcmp(argv[args], "-cge") == 0) {
@@ -886,7 +900,7 @@ int kma_main(int argc, char *argv[]) {
}
}
- if(ref_fsa) {
+ if(ref_fsa == 1) {
if(baseCall == nanoCaller) {
baseCall = &refNanoCaller;
} else {
=====================================
main.c
=====================================
@@ -18,6 +18,7 @@
*/
#define _XOPEN_SOURCE 600
#include <string.h>
+#include "db.h"
#include "dist.h"
#include "kma.h"
#include "index.h"
@@ -34,6 +35,7 @@ static int helpmessage(FILE *out) {
fprintf(out, "# %16s\t%-32s\n", "shm", "Shared memory");
fprintf(out, "# %16s\t%-32s\n", "seq2fasta", "Conversion of database to fasta");
fprintf(out, "# %16s\t%-32s\n", "dist", "Calculate distance measures between templates");
+ fprintf(out, "# %16s\t%-32s\n", "db", "Make statistics on KMA db");
fprintf(out, "# %16s\t%-32s\n", "update", "Update database to current version");
fprintf(out, "# %16s\t%-32s\n", "-c", "Citation");
fprintf(out, "# %16s\t%-32s\n", "-v", "Version");
@@ -58,6 +60,8 @@ int main(int argc, char *argv[]) {
status = dist_main(argc, argv);
} else if(strcmp(*argv, "update") == 0) {
status = update_main(argc, argv);
+ } else if(strcmp(*argv, "db") == 0) {
+ status = db_main(argc, argv);
} else {
fprintf(stderr, "Invalid option:\t%s\n", *argv);
status = helpmessage(stderr);
=====================================
mt1.c
=====================================
@@ -135,6 +135,11 @@ void runKMA_Mt1(char *templatefilename, char *outputfilename, char *exePrev, int
strcat(outputfilename, ".fsa");
consensus_out = sfopen(outputfilename, "w");
outputfilename[file_len] = 0;
+ } else if(nc == 2) {
+ alignment_out = 0;
+ strcat(outputfilename, ".fsa");
+ consensus_out = sfopen(outputfilename, "w");
+ outputfilename[file_len] = 0;
} else {
alignment_out = 0;
consensus_out = 0;
@@ -412,7 +417,7 @@ void runKMA_Mt1(char *templatefilename, char *outputfilename, char *exePrev, int
/* Output result */
fprintf(res_out, "%-12s\t%8lu\t%8d\t%8d\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%4.1e\n",
thread->template_name, read_score, 0, t_len, id, cover, q_id, q_cover, (double) depth, (double) read_score, p_value);
- if(nc == 0) {
+ if(nc != 1) {
printConsensus(aligned_assem, thread->template_name, alignment_out, consensus_out, ref_fsa);
}
/* print matrix */
=====================================
printconsensus.c
=====================================
@@ -27,21 +27,16 @@ void printConsensus(Assem *aligned_assem, char *header, FILE *alignment_out, FIL
/* print alignment */
aln_len = aligned_assem->len;
- fprintf(alignment_out, "# %s\n", header);
- for(i = 0; i < aln_len; i += 60) {
- fprintf(alignment_out, "%-10s\t%.60s\n", "template:", aligned_assem->t + i);
- fprintf(alignment_out, "%-10s\t%.60s\n", "", aligned_assem->s + i);
- fprintf(alignment_out, "%-10s\t%.60s\n\n", "query:", aligned_assem->q + i);
+ if(alignment_out) {
+ fprintf(alignment_out, "# %s\n", header);
+ for(i = 0; i < aln_len; i += 60) {
+ fprintf(alignment_out, "%-10s\t%.60s\n", "template:", aligned_assem->t + i);
+ fprintf(alignment_out, "%-10s\t%.60s\n", "", aligned_assem->s + i);
+ fprintf(alignment_out, "%-10s\t%.60s\n\n", "query:", aligned_assem->q + i);
+ }
}
-
/* Prepare consensus */
- if(ref_fsa) {
- for(i = 0; i < aln_len; ++i) {
- if(aligned_assem->q[i] == '-') {
- aligned_assem->q[i] = 'n';
- }
- }
- } else {
+ if(ref_fsa == 0) {
for(i = 0, bias = 0; i < aln_len; ++i, ++bias) {
aligned_assem->q[bias] = aligned_assem->q[i];
if(aligned_assem->q[i] == '-') {
@@ -50,7 +45,14 @@ void printConsensus(Assem *aligned_assem, char *header, FILE *alignment_out, FIL
}
aln_len = bias;
aligned_assem->q[aln_len] = 0;
+ } else if(ref_fsa == 1) {
+ for(i = 0; i < aln_len; ++i) {
+ if(aligned_assem->q[i] == '-') {
+ aligned_assem->q[i] = 'n';
+ }
+ }
}
+
/* Print consensus */
fprintf(consensus_out, ">%s\n", header);
for(i = 0; i < aln_len; i += 60) {
=====================================
runkma.c
=====================================
@@ -236,6 +236,11 @@ int runKMA(char *templatefilename, char *outputfilename, char *exePrev, int ConC
strcat(outputfilename, ".fsa");
consensus_out = sfopen(outputfilename, "w");
outputfilename[file_len] = 0;
+ } else if(nc == 2) {
+ alignment_out = 0;
+ strcat(outputfilename, ".fsa");
+ consensus_out = sfopen(outputfilename, "w");
+ outputfilename[file_len] = 0;
} else {
alignment_out = 0;
consensus_out = 0;
@@ -1234,7 +1239,7 @@ int runKMA(char *templatefilename, char *outputfilename, char *exePrev, int ConC
/* Output result */
fprintf(res_out, "%-12s\t%8ld\t%8u\t%8d\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%4.1e\n",
thread->template_name, read_score, (unsigned) expected, t_len, id, cover, q_id, q_cover, (double) depth, (double) q_value, p_value);
- if(nc == 0) {
+ if(nc != 1) {
printConsensus(aligned_assem, thread->template_name, alignment_out, consensus_out, ref_fsa);
}
/* print matrix */
@@ -1429,6 +1434,11 @@ int runKMA_MEM(char *templatefilename, char *outputfilename, char *exePrev, int
strcat(outputfilename, ".fsa");
consensus_out = sfopen(outputfilename, "w");
outputfilename[file_len] = 0;
+ } else if(nc == 2) {
+ alignment_out = 0;
+ strcat(outputfilename, ".fsa");
+ consensus_out = sfopen(outputfilename, "w");
+ outputfilename[file_len] = 0;
} else {
alignment_out = 0;
consensus_out = 0;
@@ -2386,7 +2396,7 @@ int runKMA_MEM(char *templatefilename, char *outputfilename, char *exePrev, int
/* Output result */
fprintf(res_out, "%-12s\t%8ld\t%8u\t%8d\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%4.1e\n",
thread->template_name, read_score, (unsigned) expected, t_len, id, cover, q_id, q_cover, (double) depth, (double) q_value, p_value);
- if(nc == 0) {
+ if(nc != 1) {
printConsensus(aligned_assem, thread->template_name, alignment_out, consensus_out, ref_fsa);
}
/* print matrix */
=====================================
spltdb.c
=====================================
@@ -520,6 +520,11 @@ int runKMA_spltDB(char **templatefilenames, int targetNum, char *outputfilename,
strcat(outputfilename, ".fsa");
consensus_out = sfopen(outputfilename, "w");
outputfilename[file_len] = 0;
+ } else if(nc == 2) {
+ alignment_out = 0;
+ strcat(outputfilename, ".fsa");
+ consensus_out = sfopen(outputfilename, "w");
+ outputfilename[file_len] = 0;
} else {
alignment_out = 0;
consensus_out = 0;
@@ -1639,7 +1644,7 @@ int runKMA_spltDB(char **templatefilenames, int targetNum, char *outputfilename,
/* Output result */
fprintf(res_out, "%-12s\t%8ld\t%8u\t%8d\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%8.2f\t%4.1e\n",
thread->template_name, read_score, (unsigned) expected, t_len, id, cover, q_id, q_cover, (double) depth, (double) q_value, p_value);
- if(nc == 0) {
+ if(nc != 1) {
printConsensus(aligned_assem, thread->template_name, alignment_out, consensus_out, ref_fsa);
}
/* print matrix */
=====================================
version.h
=====================================
@@ -17,4 +17,4 @@
* limitations under the License.
*/
-#define KMA_VERSION "1.3.3"
+#define KMA_VERSION "1.3.4"
View it on GitLab: https://salsa.debian.org/med-team/kma/-/compare/fdd0500f316478b0062463fbcc0b7c3952470c40...e171acafe77507a366fd399ce51ab14c69664822
--
View it on GitLab: https://salsa.debian.org/med-team/kma/-/compare/fdd0500f316478b0062463fbcc0b7c3952470c40...e171acafe77507a366fd399ce51ab14c69664822
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20201004/db82559c/attachment-0001.html>
More information about the debian-med-commit
mailing list