Commit 77a1d2eb authored by Andreas Tille's avatar Andreas Tille
Browse files

New upstream version 0.9.19+dfsg

parent ed9e0c10
Loading
Loading
Loading
Loading
+26 −2
Original line number Diff line number Diff line
@@ -2,6 +2,7 @@ cmake_minimum_required (VERSION 2.6)
project (DIAMOND)

option(BUILD_STATIC "BUILD_STATIC" OFF)
option(EXTRA "EXTRA" OFF)

if(BUILD_STATIC)
    set(CMAKE_FIND_LIBRARY_SUFFIXES ".a")
@@ -32,7 +33,6 @@ include_directories(
add_executable(diamond src/run/main.cpp
  src/basic/config.cpp
  src/util/tinythread.cpp
  src/util/compressed_stream.cpp
  src/basic/score_matrix.cpp
  src/blast/blast_filter.cpp
  src/blast/blast_seg.cpp
@@ -84,7 +84,6 @@ add_executable(diamond src/run/main.cpp
  src/dp/banded_sw.cpp
  src/data/sorted_list.cpp
  src/data/seed_set.cpp
  src/util/binary_file.cpp
  src/util/simd.cpp
  src/output/taxon_format.cpp
  src/output/view.cpp
@@ -95,8 +94,33 @@ add_executable(diamond src/run/main.cpp
  src/dp/swipe/banded_3frame_swipe.cpp
  src/dp/swipe/banded_swipe.cpp
  src/align/banded_swipe_pipeline.cpp
  src/data/ref_dictionary.cpp
  src/util/io/compressed_stream.cpp
  src/util/io/deserializer.cpp
  src/util/io/file_sink.cpp
  src/util/io/file_source.cpp
  src/util/io/input_file.cpp
  src/util/io/input_stream_buffer.cpp
  src/util/io/output_file.cpp
  src/util/io/output_stream_buffer.cpp
  src/util/io/serializer.cpp
  src/util/io/temp_file.cpp
  src/util/io/text_input_file.cpp
  src/data/taxon_list.cpp
  src/data/taxonomy_nodes.cpp
  src/util/algo/MurmurHash3.cpp
)

if(EXTRA)
  target_sources(diamond
    PUBLIC
      src/extra/benchmark.cpp
	  src/extra/test.cpp
	  src/dp/sw_3frame.cpp
  )
  add_definitions(-DEXTRA)
endif()

target_link_libraries(diamond ${ZLIB_LIBRARY} ${CMAKE_THREAD_LIBS_INIT})

install(TARGETS diamond DESTINATION bin)
+4 −8
Original line number Diff line number Diff line
@@ -9,16 +9,14 @@ DIAMOND is a sequence aligner for protein and translated DNA searches, designed

Follow me on Twitter to get notified of updates.

.. image:: https://img.shields.io/twitter/url/http/shields.io.svg?style=social&label=%40bbuchfink
.. image:: https://image.ibb.co/gAmVKR/twitter1.png
   :target: https://twitter.com/bbuchfink
.. image:: https://badges.gitter.im/diamond-aligner/Lobby.svg
   :alt: Join the chat at https://gitter.im/diamond-aligner/Lobby
   :target: https://gitter.im/diamond-aligner/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge
.. image:: https://img.shields.io/github/downloads/bbuchfink/diamond/total.svg?label=Downloads
   :target: https://github.com/bbuchfink/diamond/releases/download/v0.9.14/diamond-linux64.tar.gz
.. image:: https://img.shields.io/conda/dn/bioconda/diamond.svg?label=BioConda%20install
.. image:: https://anaconda.org/bioconda/diamond/badges/downloads.svg
   :target: https://anaconda.org/bioconda/diamond
.. image:: https://img.shields.io/badge/Google%20Scholar-446-blue.svg
.. image:: https://img.shields.io/badge/Google%20Scholar-491-blue.svg
   :target: https://scholar.google.de/citations?user=kjPIF1cAAAAJ

Quick start guide
@@ -27,7 +25,7 @@ Please read the `manual <https://github.com/bbuchfink/diamond/raw/master/diamond

Installing the software on your system may be done by downloading it in binary format for immediate use::

    wget http://github.com/bbuchfink/diamond/releases/download/v0.9.17/diamond-linux64.tar.gz
    wget http://github.com/bbuchfink/diamond/releases/download/v0.9.19/diamond-linux64.tar.gz
    tar xzf diamond-linux64.tar.gz

The extracted ``diamond`` binary file should be moved to a directory contained in your executable search path (PATH environment variable).
@@ -55,5 +53,3 @@ About
DIAMOND is developed by Benjamin Buchfink. Feel free to contact me for support (`Email <mailto:buchfink@gmail.com>`_ `Twitter <http://twitter.com/bbuchfink>`_).

If you use DIAMOND in published research, please cite B. Buchfink, Xie C., D. Huson, "Fast and sensitive protein alignment using DIAMOND", Nature Methods 12, 59-60 (2015).

.. image:: https://ga-beacon.appspot.com/UA-109667396-1/diamond?pixel
+15 −2
Original line number Diff line number Diff line
@@ -4,7 +4,6 @@ g++ -DNDEBUG -O3 -Wno-deprecated-declarations $1 $2 $3 \
  src/run/main.cpp \
  src/basic/config.cpp \
  src/util/tinythread.cpp \
  src/util/compressed_stream.cpp \
  src/basic/score_matrix.cpp \
  src/blast/blast_filter.cpp \
  src/blast/blast_seg.cpp \
@@ -48,7 +47,6 @@ g++ -DNDEBUG -O3 -Wno-deprecated-declarations $1 $2 $3 \
  src/dp/banded_sw.cpp \
  src/data/sorted_list.cpp \
  src/data/seed_set.cpp \
  src/util/binary_file.cpp \
  src/util/simd.cpp \
  src/output/taxon_format.cpp \
  src/output/view.cpp \
@@ -59,4 +57,19 @@ g++ -DNDEBUG -O3 -Wno-deprecated-declarations $1 $2 $3 \
  src/dp/swipe/banded_3frame_swipe.cpp \
  src/dp/swipe/banded_swipe.cpp \
  src/align/banded_swipe_pipeline.cpp \
  src/data/ref_dictionary.cpp \
  src/util/io/compressed_stream.cpp \
  src/util/io/deserializer.cpp \
  src/util/io/file_sink.cpp \
  src/util/io/file_source.cpp \
  src/util/io/input_file.cpp \
  src/util/io/input_stream_buffer.cpp \
  src/util/io/output_file.cpp \
  src/util/io/output_stream_buffer.cpp \
  src/util/io/serializer.cpp \
  src/util/io/temp_file.cpp \
  src/util/io/text_input_file.cpp \
  src/data/taxon_list.cpp \
  src/data/taxonomy_nodes.cpp \
  src/util/algo/MurmurHash3.cpp \
-lz -lpthread -o diamond
+11 −0
Original line number Diff line number Diff line
[0.9.19]
- Fixed a bug in the --un function to write unaligned reads.
- Fixed an issue in the LCA algorithm that could cause an assignment to a higher node.
- --taxonmap and --taxonnodes parameters now apply exclusively to the makedb command.
- Added option --taxonlist to filter searches by subject taxonomic id.
- Changed database format; rebuilding is required.

[0.9.18]
- Optimized output writing performance.
- Fixed a bug in the XML output format.

[0.9.17]
- Fixed a compiler error on FreeBSD.
- Added option --range-culling.
+9 −8
Original line number Diff line number Diff line
@@ -62,7 +62,7 @@ auto_ptr<Queue> Align_fetcher::queue_;
vector<hit>::iterator Align_fetcher::it_;
vector<hit>::iterator Align_fetcher::end_;

void align_worker(size_t thread_id)
void align_worker(size_t thread_id, const Parameters *params, const Metadata *metadata)
{
	Align_fetcher hits;
	Statistics stat;
@@ -74,7 +74,7 @@ void align_worker(size_t thread_id)
				buf = new TextBuffer;
				const char *query_title = query_ids::get()[hits.query].c_str();
				output_format->print_query_intro(hits.query, query_title, get_source_query_len((unsigned)hits.query), *buf, true);
				output_format->print_query_epilog(*buf, query_title, true);
				output_format->print_query_epilog(*buf, query_title, true, *params);
			}
			OutputSink::get().push(hits.query, buf);
			continue;
@@ -82,18 +82,18 @@ void align_worker(size_t thread_id)

		QueryMapper *mapper;
		if (config.ext == Config::swipe)
			mapper = new ExtensionPipeline::Swipe::Pipeline(hits.query, hits.begin, hits.end);
			mapper = new ExtensionPipeline::Swipe::Pipeline(*params, hits.query, hits.begin, hits.end);
		else if (config.frame_shift != 0)
			mapper = new ExtensionPipeline::BandedSwipe::Pipeline(hits.query, hits.begin, hits.end, dp_stat);
			mapper = new ExtensionPipeline::BandedSwipe::Pipeline(*params, hits.query, hits.begin, hits.end, dp_stat);
		else
			mapper = new ExtensionPipeline::Greedy::Pipeline(hits.query, hits.begin, hits.end);
			mapper = new ExtensionPipeline::Greedy::Pipeline(*params, hits.query, hits.begin, hits.end);
		mapper->init();
		mapper->run(stat);

		TextBuffer *buf = 0;
		if (*output_format != Output_format::null) {
			buf = new TextBuffer;
			const bool aligned = mapper->generate_output(*buf, stat);
			const bool aligned = mapper->generate_output(*buf, stat, *metadata);
			if (aligned && !config.unaligned.empty())
				query_aligned[hits.query] = true;
		}
@@ -104,7 +104,7 @@ void align_worker(size_t thread_id)
	::dp_stat += dp_stat;
}

void align_queries(Trace_pt_buffer &trace_pts, Output_stream* output_file)
void align_queries(Trace_pt_buffer &trace_pts, OutputFile* output_file, const Parameters &params, const Metadata &metadata)
{
	const size_t max_size = (size_t)std::min(config.chunk_size*1e9 * 9 * 2 / config.lowmem, 2e9);
	pair<size_t, size_t> query_range;
@@ -127,7 +127,8 @@ void align_queries(Trace_pt_buffer &trace_pts, Output_stream* output_file)
			threads.push_back(launch_thread(heartbeat_worker, query_range.second));
		size_t n_threads = (config.threads_align == 0 ? config.threads_ : config.threads_align);
		for (size_t i = 0; i < n_threads; ++i)
			threads.push_back(launch_thread(static_cast<void(*)(size_t)>(&align_worker), i));
			//threads.push_back(launch_thread(static_cast<void(*)(size_t)>(&align_worker), i));
			threads.push_back(launch_thread(align_worker, i, &params, &metadata));
		threads.join_all();
		timer.finish();

Loading