From 3e526e49a2d3608950f2a528ba6309ca41e03a74 Mon Sep 17 00:00:00 2001 From: Andrew D Smith Date: Fri, 4 Aug 2023 19:42:12 -0700 Subject: [PATCH 1/4] abismal.cpp now gets its version number from the config.h file --- src/abismal.cpp | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/src/abismal.cpp b/src/abismal.cpp index b4cd7c1..7028e34 100644 --- a/src/abismal.cpp +++ b/src/abismal.cpp @@ -18,6 +18,7 @@ #include "abismal.hpp" #include +#include #include #include #include @@ -171,9 +172,9 @@ update_max_read_length(size_t &max_length, const vector &reads) { } struct se_element { // size = 8 - score_t diffs; // 2 bytes - flags_t flags; // 2 bytes - uint32_t pos; // 4 bytes + score_t diffs; // 2 bytes + flags_t flags; // 2 bytes + uint32_t pos; // 4 bytes se_element(): diffs(MAX_DIFFS), flags(0), pos(0) {} @@ -2041,8 +2042,7 @@ file_exists(const string &filename) { } static int -abismal_make_sam_header(const ChromLookup &cl, const string program_name, - const string program_version, const int argc, +abismal_make_sam_header(const ChromLookup &cl, const int argc, const char **argv, bamxx::bam_header &hdr) { assert(cl.names.size() > 2); // two entries exist for the padding assert(cl.starts.size() == cl.names.size() + 1); @@ -2060,14 +2060,13 @@ abismal_make_sam_header(const ChromLookup &cl, const string program_name, // chromosome sizes const size_t n_chroms = names.size(); - for (size_t i = 0; i < n_chroms; ++i) { + for (size_t i = 0; i < n_chroms; ++i) out << "@SQ" << '\t' << "SN:" << names[i] << '\t' << "LN:" << sizes[i] << '\n'; - } // program details - out << "@PG" << '\t' << "ID:" << program_name << '\t' - << "VN:" << program_version << '\t'; + out << "@PG" << '\t' << "ID:" + << "ABISMAL" << '\t' << "VN:" << VERSION << '\t'; // how the program was run std::ostringstream the_command; @@ -2082,7 +2081,6 @@ abismal_make_sam_header(const ChromLookup &cl, const string program_name, int abismal(int argc, const char **argv) { try { - static const string ABISMAL_VERSION = "3.1.1"; bool VERBOSE = false; bool GA_conversion = false; bool allow_ambig = false; @@ -2248,8 +2246,7 @@ abismal(int argc, const char **argv) { if (!out) throw runtime_error("failed to open output file: " + outfile); bamxx::bam_header hdr; - int ret = abismal_make_sam_header(abismal_index.cl, "ABISMAL", - ABISMAL_VERSION, argc, argv, hdr); + int ret = abismal_make_sam_header(abismal_index.cl, argc, argv, hdr); if (ret < 0) throw runtime_error("error formatting header"); From bdf0e895292bd1ebd81e3b5ca7b75f4b0c4f8904 Mon Sep 17 00:00:00 2001 From: Andrew D Smith Date: Fri, 4 Aug 2023 19:43:41 -0700 Subject: [PATCH 2/4] Updating test output hashes for version number change from 3.1.1 to 3.2.0 --- data/md5sum.txt | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/data/md5sum.txt b/data/md5sum.txt index 3a5313f..b91f82d 100644 --- a/data/md5sum.txt +++ b/data/md5sum.txt @@ -4,15 +4,14 @@ b9699416969133224b620f05af97ac90 tests/reads_pbat_pe_1.fq 12c9d36ab3bf2b9ecb5683d7a093a10d tests/reads_pbat_pe_2.fq 3edbf931e6f0da55a50b24e01a975565 tests/reads_pbat_pe.mstats -51b695cd3aeb3cead392821628acf0f1 tests/reads_pbat_pe.sam -58d6c1157b187a66d43087fe3e70a38c tests/reads_pbat.sam 8e5ad0faefe241de9c2c5748e005e2e8 tests/reads_pe_1.fq 4ebacfec717182fafce46b037591b228 tests/reads_pe_2.fq 072a7df62d45dc3d3d4350d79efc9ca1 tests/reads_pe.mstats -56318794f9e55549c9050a636161e883 tests/reads_pe.sam e66339e591563032af436ca2af9b75b1 tests/reads_rpbat_pe_1.fq aed5705c4a99601d5799fc8ee42af5b2 tests/reads_rpbat_pe_2.fq da00a63969113e09406b61cbe280daa5 tests/reads_rpbat_pe.mstats -7f3f547ff06296ef2fcc7d1cb8169766 tests/reads_rpbat_pe.sam -50ec2af709639fa242654f9b3a46981b tests/reads.sam 3ba5a1c4c420ca7a2dbd88290033c3bc tests/tRex1.idx +cd4a9d6b8c9b00254c53e3e5e5cd249e tests/reads_pbat_pe.sam +c466e11e3ed0bfe32c4baa1f16096a95 tests/reads_pe.sam +c5bf84d3e4e01e27804d39321569c11c tests/reads_rpbat_pe.sam +9cab40d2130b4eb9d95f5694d184a5e1 tests/reads.sam From fdff9e221ef77dbbe5aa2d4ed4f7d47230b1ad02 Mon Sep 17 00:00:00 2001 From: Andrew D Smith Date: Fri, 4 Aug 2023 19:44:10 -0700 Subject: [PATCH 3/4] Updating authors --- Makefile.am | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile.am b/Makefile.am index 8edbe54..c496972 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,8 +1,8 @@ # This file is part of abismal # -# Copyright (C) 2018-2020: Andrew D. Smith +# Copyright (C) 2018-2023: Andrew D. Smith and Guilherme de Sena Brandine # -# Authors: Andrew D. Smith +# Authors: Andrew D. Smith and Guilherme de Sena Brandine # # This is free software: you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by From 136fef20007ba5f33c119ce0456fd7b7b9a19e9f Mon Sep 17 00:00:00 2001 From: Andrew D Smith Date: Fri, 4 Aug 2023 19:44:40 -0700 Subject: [PATCH 4/4] Updating version numbers to 3.2.0 --- README.md | 12 ++++++------ configure.ac | 4 ++-- docs/MANUAL.md | 8 ++++---- docs/abismal.1 | 8 ++++---- docs/abismal.html | 8 ++++---- 5 files changed, 20 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index 2c976f3..20e04e2 100644 --- a/README.md +++ b/README.md @@ -53,9 +53,9 @@ If you don't have adminstrator privileges, there are other options. If you have the `libhts-dev` installed, to build `abismal` the following should work: ```console -$ wget https://github.com/smithlabcode/abismal/releases/download/v3.1.1/abismal-3.1.1.tar.gz -$ tar -zxvf abismal-3.1.1.tar.gz -$ cd abismal-3.1.1 +$ wget https://github.com/smithlabcode/abismal/releases/download/v3.2.0/abismal-3.2.0.tar.gz +$ tar -zxvf abismal-3.2.0.tar.gz +$ cd abismal-3.2.0 $ mkdir build && cd build $ ../configure --prefix=/where/you/want/abismal $ make @@ -84,9 +84,9 @@ be needed below. If you don't already have `abismal` downloaded, the next step is to download it. Here we will assume you are using a release rather than a clone. To build from a clone involves at least one more step. ```console -$ wget https://github.com/smithlabcode/abismal/releases/download/v3.1.1/abismal-3.1.1.tar.gz -$ tar -zxvf abismal-3.1.1.tar.gz -$ cd abismal-3.1.1 +$ wget https://github.com/smithlabcode/abismal/releases/download/v3.2.0/abismal-3.2.0.tar.gz +$ tar -zxvf abismal-3.2.0.tar.gz +$ cd abismal-3.2.0 ``` Finally, these steps build the software: ```console diff --git a/configure.ac b/configure.ac index d2d00bf..1e65948 100644 --- a/configure.ac +++ b/configure.ac @@ -1,6 +1,6 @@ dnl This file is part of abismal dnl -dnl Copyright (C) 2019-2022: Andrew D. Smith and Guilherme de Sena Brandine +dnl Copyright (C) 2019-2023: Andrew D. Smith and Guilherme de Sena Brandine dnl dnl Authors: Andrew D. Smith and Guilherme de Sena Brandine dnl @@ -14,7 +14,7 @@ dnl but WITHOUT ANY WARRANTY; without even the implied warranty of dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU dnl General Public License for more details. -AC_INIT([abismal], [3.1.1], [andrewds@usc.edu], +AC_INIT([abismal], [3.2.0], [andrewds@usc.edu], [abismal], [https://github.com/smithlabcode/abismal]) dnl the config.h is not currently #included in the source, and only diff --git a/docs/MANUAL.md b/docs/MANUAL.md index 4ef602f..b5e8356 100644 --- a/docs/MANUAL.md +++ b/docs/MANUAL.md @@ -49,9 +49,9 @@ substantially. Run the following commands to install abismal ``` -wget https://github.com/smithlabcode/abismal/releases/download/v3.1.1/abismal-3.1.1.tar.gz -tar -xvzf abismal-3.1.1.tar.gz -cd abismal-3.1.1 +wget https://github.com/smithlabcode/abismal/releases/download/v3.2.0/abismal-3.2.0.tar.gz +tar -xvzf abismal-3.2.0.tar.gz +cd abismal-3.2.0 ./configure --prefix=$(pwd) make make install @@ -317,7 +317,7 @@ sequence. The last line of the headers is a copy of how the program was called to generate the SAM output, and is of the form ``` -@PG ID:ABISMAL VN:3.1.1 CL:"[command-call]" +@PG ID:ABISMAL VN:3.2.0 CL:[command-call] ``` where [command-call] is the shell command used to run abismal. diff --git a/docs/abismal.1 b/docs/abismal.1 index 01c97a8..448698d 100644 --- a/docs/abismal.1 +++ b/docs/abismal.1 @@ -57,9 +57,9 @@ Run the following commands to install abismal .IP .nf \f[C] -wget https://github.com/smithlabcode/abismal/releases/download/v3.1.1/abismal-3.1.1.tar.gz -tar -xvzf abismal-3.1.1.tar.gz -cd abismal-3.1.1 +wget https://github.com/smithlabcode/abismal/releases/download/v3.2.0/abismal-3.2.0.tar.gz +tar -xvzf abismal-3.2.0.tar.gz +cd abismal-3.2.0 \&./configure --prefix=$(pwd) make make install @@ -364,7 +364,7 @@ generate the SAM output, and is of the form .IP .nf \f[C] -\[at]PG ID:ABISMAL VN:3.1.1 CL:\[dq][command-call]\[dq] +\[at]PG ID:ABISMAL VN:3.2.0 CL:\[dq][command-call]\[dq] \f[R] .fi .PP diff --git a/docs/abismal.html b/docs/abismal.html index 48fa4c5..cd8f0b7 100644 --- a/docs/abismal.html +++ b/docs/abismal.html @@ -65,9 +65,9 @@

DESCRIPTION

absimal was built to map short reads of up to 250 bases. It should successfully map reads of size up to 1 million, but because it uses very short seeds for filtration, the mapping time will increase substantially.

QUICK INSTALLATION

Run the following commands to install abismal

-
wget https://github.com/smithlabcode/abismal/releases/download/v3.1.1/abismal-3.1.1.tar.gz
-tar -xvzf abismal-3.1.1.tar.gz
-cd abismal-3.1.1
+
wget https://github.com/smithlabcode/abismal/releases/download/v3.2.0/abismal-3.2.0.tar.gz
+tar -xvzf abismal-3.2.0.tar.gz
+cd abismal-3.2.0
 ./configure --prefix=$(pwd)
 make
 make install
@@ -204,7 +204,7 @@

Output headers

@SQ SN:[chrom-name] LN:[chrom-length]

where [chrom-name] is given by the first word of the chromosome name in the FASTA file (anything after the first white space is deleted), and [chrom-length] is the number of bases in the chromosome sequence.

The last line of the headers is a copy of how the program was called to generate the SAM output, and is of the form

-
@PG ID:ABISMAL  VN:3.1.1  CL:"[command-call]"
+
@PG ID:ABISMAL  VN:3.2.0  CL:"[command-call]"

where [command-call] is the shell command used to run abismal.

Output mapped lines

Following the header lines, reads that are mapped once (or at least once if the -a flag is used) are reported. Each read is a set of thirteen tab-separated fields as follows.