[med-svn] [Git][med-team/wtdbg2][master] 6 commits: Add autopkgtests

Nilesh Patra gitlab at salsa.debian.org
Sun Aug 9 16:07:00 BST 2020



Nilesh Patra pushed to branch master at Debian Med / wtdbg2


Commits:
13211a71 by Nilesh Patra at 2020-08-09T14:49:01+00:00
Add autopkgtests

- - - - -
8d220b6f by Nilesh Patra at 2020-08-09T14:49:22+00:00
Save up space by not extracting the binary

- - - - -
89f01792 by Nilesh Patra at 2020-08-09T14:49:45+00:00
New binary: wtdbg2-examples

- - - - -
13b8ea5b by Nilesh Patra at 2020-08-09T14:50:11+00:00
Minor fixes on manpages

- - - - -
7b2d763b by Nilesh Patra at 2020-08-09T20:28:05+05:30
Fix spellings

- - - - -
e56ba773 by Nilesh Patra at 2020-08-09T20:34:28+05:30
Change arch of example binary to all

- - - - -


10 changed files:

- debian/control
- debian/mans/kbm2.1
- debian/mans/wtdbg2.1
- debian/rules
- + debian/source/include-binaries
- + debian/tests/README
- + debian/tests/control
- + debian/tests/data/selfSampleData.tar.gz
- + debian/tests/run-unit-test
- + debian/wtdbg2-examples.docs


Changes:

=====================================
debian/control
=====================================
@@ -3,7 +3,7 @@ Maintainer: Debian Med Packaging Team <debian-med-packaging at lists.alioth.debian.
 Uploaders: Andreas Tille <tille at debian.org>
 Section: science
 Priority: optional
-Build-Depends: debhelper-compat (= 12),
+Build-Depends: debhelper-compat (= 13),
                zlib1g-dev,
                libsimde-dev
 Standards-Version: 4.5.0
@@ -19,7 +19,8 @@ Depends: ${shlibs:Depends},
 Suggests: ${perl:Depends},
           minimap2,
           samtools,
-          mummer
+          mummer,
+Recommends: wtdbg2-examples
 Description: de novo sequence assembler for long noisy reads
  Wtdbg2 is a de novo sequence assembler for long noisy reads produced by
  PacBio or Oxford Nanopore Technologies (ONT). It assembles raw reads
@@ -34,3 +35,19 @@ Description: de novo sequence assembler for long noisy reads
  (FBG). It is akin to De Bruijn graph but permits mismatches/gaps and
  keeps read paths when collapsing k-mers. The use of FBG distinguishes
  wtdbg2 from the majority of long-read assemblers.
+
+Package: wtdbg2-examples
+Architecture: all
+Depends: ${shlibs:Depends},
+         ${misc:Depends}
+Enhances: wtdbg2
+Description: Examples for wtdbg - de novo sequence assembler
+ Wtdbg2 is a de novo sequence assembler for long noisy reads produced by
+ PacBio or Oxford Nanopore Technologies (ONT). It assembles raw reads
+ without error correction and then builds the consensus from intermediate
+ assembly output. Wtdbg2 is able to assemble the human and even the 32Gb
+ Axolotl genome at a speed tens of times faster than CANU and FALCON
+ while producing contigs of comparable base accuracy.
+ .
+ This package contains a test data set as well as sample scripts
+ running some test suite provided by Debian also as autopkgtest.


=====================================
debian/mans/kbm2.1
=====================================
@@ -56,7 +56,7 @@ Filter low complexity bins (#indexed_kmer less than <\-O>), [2]
 .TP
 \fB\-S\fR <float>
 Subsampling kmers, 1/(<\-S>) kmers are indexed, [4.00]
-\fB\-S\fR is very useful in saving memeory and speeding up
+\fB\-S\fR is very useful in saving memory and speeding up
 please note that subsampling kmers will have less matched length
 .TP
 \fB\-B\fR <int>


=====================================
debian/mans/wtdbg2.1
=====================================
@@ -58,7 +58,7 @@ Filter high frequency kmers, maybe repetitive, [1000.05]
 .TP
 \fB\-S\fR <float>
 Subsampling kmers, 1/(<\-S>) kmers are indexed, [4.00]
-\fB\-S\fR is very useful in saving memeory and speeding up
+\fB\-S\fR is very useful in saving memory and speeding up
 please note that subsampling kmers will have less matched length
 .TP
 \fB\-l\fR <float>
@@ -178,7 +178,7 @@ Retain dovetail overlaps only, the max overhang size is <\-\-aln\-dovetail>, the
 .HP
 \fB\-\-aln\-strand\fR <int>
 .IP
-1: forward, 2: reverse, 3: both. Please don't change the deault vaule 3, unless you exactly know what you are doing
+1: forward, 2: reverse, 3: both. Please don't change the deault value 3, unless you exactly know what you are doing
 .HP
 \fB\-\-aln\-maxhit\fR <int>
 .IP
@@ -303,7 +303,7 @@ Don't attempt to rescue low coverage edges
 .HP
 \fB\-\-node\-min\fR <int>
 .IP
-Min depth of an interval to be selected as valid node. Defaultly, this value is automaticly the same with \fB\-\-edge\-min\fR.
+Min depth of an interval to be selected as valid node. Defaultly, this value is automatically the same with \fB\-\-edge\-min\fR.
 .HP
 \fB\-\-node\-max\fR <int>
 .IP
@@ -364,7 +364,7 @@ Min length of contigs to be output, 5000
 .HP
 \fB\-\-ctg\-min\-nodes\fR <int>
 .IP
-Min num of nodes in a contig to be ouput, 3
+Min num of nodes in a contig to be output, 3
 .HP
 \fB\-\-minimal\-output\fR
 .IP


=====================================
debian/rules
=====================================
@@ -19,6 +19,12 @@ libexecdir=$(prefix)/lib/$(DEB_SOURCE)
 	dh $@
 
 override_dh_auto_build:
+	sed -i 's/\/usr\/bin\/env perl/\/usr\/bin\/perl/' scripts/*
+	sed -i 's/memeory/memory/' *.c *.h *.md
+	sed -i 's/automaticly/automatically/' *.c
+	sed -i 's/ouput/output/' *.c
+	sed -i 's/vaule/value/' *.c
+	sed -i 's/annonymous/anonymous/' *.h
 ifeq (amd64,$(DEB_HOST_ARCH))
 	mkdir -p $(prefix)
 	mkdir -p $(libexecdir)


=====================================
debian/source/include-binaries
=====================================
@@ -0,0 +1 @@
+debian/tests/data/selfSampleData.tar.gz


=====================================
debian/tests/README
=====================================
@@ -0,0 +1,5 @@
+Tests for wtdbg2
+=================
+
+The data for tests has been referenced from:
+	http://www.cbcb.umd.edu/software/PBcR/data/selfSampleData.tar.gz


=====================================
debian/tests/control
=====================================
@@ -0,0 +1,4 @@
+Tests: run-unit-test
+Depends: @, bwa, minimap2, samtools
+Restrictions: allow-stderr
+


=====================================
debian/tests/data/selfSampleData.tar.gz
=====================================
Binary files /dev/null and b/debian/tests/data/selfSampleData.tar.gz differ


=====================================
debian/tests/run-unit-test
=====================================
@@ -0,0 +1,43 @@
+#!/bin/bash
+set -e
+
+pkg=wtdbg2
+
+if [ "${AUTOPKGTEST_TMP}" = "" ] ; then
+  AUTOPKGTEST_TMP=$(mktemp -d /tmp/${pkg}-test.XXXXXX)
+  trap "rm -rf ${AUTOPKGTEST_TMP}" 0 INT QUIT ABRT PIPE TERM
+fi
+
+cp /usr/share/doc/${pkg}-examples/* -a "${AUTOPKGTEST_TMP}"
+
+cd "${AUTOPKGTEST_TMP}"
+gunzip -r *
+tar -xvf *.tar
+cd selfSampleData
+
+# Checks whether file checksum is same as expected
+function check_same()
+{
+	# $1 : file name
+	# $2 : checksum value
+	[ "$(cat $1 | md5sum | awk '{print $1}')" == $2 ] || exit 1
+}
+
+echo "Begin Execution"
+wtdbg2 -t 16 -x rs -g 4.6m -o dbg pacbio_filtered.fastq
+
+# Step by step commandlines
+# assemble long reads
+wtdbg2 -x rs -g 4.6m -i pacbio_filtered.fastq -t 16 -fo dbg
+
+# derive consensus
+wtpoa-cns -t 16 -i dbg.ctg.lay.gz -fo dbg.raw.fa
+check_same dbg.raw.fa a2c479242d7c6ad6c8ffd979b821aa01
+echo "PASS"
+
+# polish consensus, not necessary if you want to polish the assemblies using other tools
+minimap2 -t16 -ax map-pb -r2k dbg.raw.fa pacbio_filtered.fastq | samtools sort - at 4 >dbg.bam
+samtools view -F0x900 dbg.bam | wtpoa-cns -t 16 -d dbg.raw.fa -i - -fo dbg.cns.fa
+check_same dbg.cns.fa 62a41e5cb7a5e702523237f4ab65c376
+echo "PASS"
+


=====================================
debian/wtdbg2-examples.docs
=====================================
@@ -0,0 +1 @@
+debian/tests/data/*



View it on GitLab: https://salsa.debian.org/med-team/wtdbg2/-/compare/7fe1a0d7eef40d354a8bba4b56a1fd2149cbbf63...e56ba7735427e54e99ee73d083a4ee8a78724aa2

-- 
View it on GitLab: https://salsa.debian.org/med-team/wtdbg2/-/compare/7fe1a0d7eef40d354a8bba4b56a1fd2149cbbf63...e56ba7735427e54e99ee73d083a4ee8a78724aa2
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/20200809/9b68785e/attachment-0001.html>


More information about the debian-med-commit mailing list