|
| 1 | +From 0f4d6caf3c4e4ecf4f3ebc2651bb5a952a40b3fc Mon Sep 17 00:00:00 2001 |
| 2 | +From: Enrico Seiler < [email protected]> |
| 3 | +Date: Wed, 12 Feb 2025 14:39:21 +0100 |
| 4 | +Subject: [PATCH 8/8] [NOAPI][DETAIL] Put SDSL into contrib |
| 5 | + |
| 6 | +--- |
| 7 | + .../range/container_push_back_benchmark.cpp | 5 ++--- |
| 8 | + .../range/container_seq_read_benchmark.cpp | 5 ++--- |
| 9 | + .../range/container_seq_write_benchmark.cpp | 5 ++--- |
| 10 | + .../core/detail/template_inspection_usage.cpp | 2 ++ |
| 11 | + test/snippet/utility/tuple_utility.cpp | 2 ++ |
| 12 | + .../container/container_concept_test.cpp | 11 +++++------ |
| 13 | + .../interleaved_bloom_filter_test.cpp | 2 +- |
| 14 | + ...fm_index_cursor_collection_test_template.hpp | 17 ++++++++++------- |
| 15 | + .../fm_index_cursor_test_template.hpp | 17 ++++++++++------- |
| 16 | + test/unit/search/sdsl_index_test.cpp | 2 +- |
| 17 | + .../utility/bloom_filter/bloom_filter_test.cpp | 2 +- |
| 18 | + 11 files changed, 38 insertions(+), 32 deletions(-) |
| 19 | + |
| 20 | +diff --git a/test/performance/range/container_push_back_benchmark.cpp b/test/performance/range/container_push_back_benchmark.cpp |
| 21 | +index 32470ac9b..59860b0c7 100644 |
| 22 | +--- a/test/performance/range/container_push_back_benchmark.cpp |
| 23 | ++++ b/test/performance/range/container_push_back_benchmark.cpp |
| 24 | +@@ -11,16 +11,15 @@ |
| 25 | + #include <list> |
| 26 | + #include <vector> |
| 27 | + |
| 28 | +-#include <sdsl/int_vector.hpp> |
| 29 | +- |
| 30 | + #include <seqan3/alignment/decorator/gap_decorator.hpp> |
| 31 | + #include <seqan3/alphabet/all.hpp> |
| 32 | + #include <seqan3/alphabet/container/bitpacked_sequence.hpp> |
| 33 | ++#include <seqan3/contrib/sdsl-lite.hpp> |
| 34 | + #include <seqan3/test/seqan2.hpp> |
| 35 | + #include <seqan3/utility/container/small_vector.hpp> |
| 36 | + |
| 37 | + template <typename t> |
| 38 | +-using sdsl_int_vec = sdsl::int_vector<sizeof(t) * 8>; |
| 39 | ++using sdsl_int_vec = seqan3::contrib::sdsl::int_vector<sizeof(t) * 8>; |
| 40 | + |
| 41 | + template <typename t> |
| 42 | + using small_vec = seqan3::small_vector<t, 10'000>; |
| 43 | +diff --git a/test/performance/range/container_seq_read_benchmark.cpp b/test/performance/range/container_seq_read_benchmark.cpp |
| 44 | +index 6a3e41fc5..e460a29f3 100644 |
| 45 | +--- a/test/performance/range/container_seq_read_benchmark.cpp |
| 46 | ++++ b/test/performance/range/container_seq_read_benchmark.cpp |
| 47 | +@@ -11,17 +11,16 @@ |
| 48 | + #include <list> |
| 49 | + #include <vector> |
| 50 | + |
| 51 | +-#include <sdsl/int_vector.hpp> |
| 52 | +- |
| 53 | + #include <seqan3/alignment/decorator/gap_decorator.hpp> |
| 54 | + #include <seqan3/alphabet/all.hpp> |
| 55 | + #include <seqan3/alphabet/container/bitpacked_sequence.hpp> |
| 56 | ++#include <seqan3/contrib/sdsl-lite.hpp> |
| 57 | + #include <seqan3/test/performance/sequence_generator.hpp> |
| 58 | + #include <seqan3/test/seqan2.hpp> |
| 59 | + #include <seqan3/utility/container/small_vector.hpp> |
| 60 | + |
| 61 | + template <typename t> |
| 62 | +-using sdsl_int_vec = sdsl::int_vector<sizeof(t) * 8>; |
| 63 | ++using sdsl_int_vec = seqan3::contrib::sdsl::int_vector<sizeof(t) * 8>; |
| 64 | + |
| 65 | + template <typename t> |
| 66 | + using small_vec = seqan3::small_vector<t, 10'000>; |
| 67 | +diff --git a/test/performance/range/container_seq_write_benchmark.cpp b/test/performance/range/container_seq_write_benchmark.cpp |
| 68 | +index 193ab6965..a990d0abe 100644 |
| 69 | +--- a/test/performance/range/container_seq_write_benchmark.cpp |
| 70 | ++++ b/test/performance/range/container_seq_write_benchmark.cpp |
| 71 | +@@ -11,17 +11,16 @@ |
| 72 | + #include <list> |
| 73 | + #include <vector> |
| 74 | + |
| 75 | +-#include <sdsl/int_vector.hpp> |
| 76 | +- |
| 77 | + #include <seqan3/alignment/decorator/gap_decorator.hpp> |
| 78 | + #include <seqan3/alphabet/all.hpp> |
| 79 | + #include <seqan3/alphabet/container/bitpacked_sequence.hpp> |
| 80 | ++#include <seqan3/contrib/sdsl-lite.hpp> |
| 81 | + #include <seqan3/test/performance/sequence_generator.hpp> |
| 82 | + #include <seqan3/test/seqan2.hpp> |
| 83 | + #include <seqan3/utility/container/small_vector.hpp> |
| 84 | + |
| 85 | + template <typename t> |
| 86 | +-using sdsl_int_vec = sdsl::int_vector<sizeof(t) * 8>; |
| 87 | ++using sdsl_int_vec = seqan3::contrib::sdsl::int_vector<sizeof(t) * 8>; |
| 88 | + |
| 89 | + template <typename t> |
| 90 | + using small_vec = seqan3::small_vector<t, 10'000>; |
| 91 | +diff --git a/test/snippet/core/detail/template_inspection_usage.cpp b/test/snippet/core/detail/template_inspection_usage.cpp |
| 92 | +index 74b798cea..fd0070cab 100644 |
| 93 | +--- a/test/snippet/core/detail/template_inspection_usage.cpp |
| 94 | ++++ b/test/snippet/core/detail/template_inspection_usage.cpp |
| 95 | +@@ -1,3 +1,5 @@ |
| 96 | ++#include <tuple> |
| 97 | ++ |
| 98 | + #include <seqan3/core/detail/template_inspection.hpp> |
| 99 | + #include <seqan3/utility/type_list/type_list.hpp> |
| 100 | + |
| 101 | +diff --git a/test/snippet/utility/tuple_utility.cpp b/test/snippet/utility/tuple_utility.cpp |
| 102 | +index 91dbe8f0c..211c57557 100644 |
| 103 | +--- a/test/snippet/utility/tuple_utility.cpp |
| 104 | ++++ b/test/snippet/utility/tuple_utility.cpp |
| 105 | +@@ -1,3 +1,5 @@ |
| 106 | ++#include <string> |
| 107 | ++ |
| 108 | + #include <seqan3/utility/tuple/split.hpp> |
| 109 | + |
| 110 | + int main() |
| 111 | +diff --git a/test/unit/alphabet/container/container_concept_test.cpp b/test/unit/alphabet/container/container_concept_test.cpp |
| 112 | +index f6dd0d60f..e62982fb0 100644 |
| 113 | +--- a/test/unit/alphabet/container/container_concept_test.cpp |
| 114 | ++++ b/test/unit/alphabet/container/container_concept_test.cpp |
| 115 | +@@ -14,13 +14,12 @@ |
| 116 | + #include <string> |
| 117 | + #include <vector> |
| 118 | + |
| 119 | +-#include <sdsl/int_vector.hpp> |
| 120 | +- |
| 121 | + #include <seqan3/alphabet/container/bitpacked_sequence.hpp> |
| 122 | + #include <seqan3/alphabet/container/concatenated_sequences.hpp> |
| 123 | + #include <seqan3/alphabet/nucleotide/dna4.hpp> |
| 124 | + #include <seqan3/alphabet/quality/phred42.hpp> |
| 125 | + #include <seqan3/alphabet/quality/qualified.hpp> |
| 126 | ++#include <seqan3/contrib/sdsl-lite.hpp> |
| 127 | + #include <seqan3/utility/container/concept.hpp> |
| 128 | + |
| 129 | + TEST(range_concept, forward_range) |
| 130 | +@@ -179,10 +178,10 @@ TEST(container, reservible_container) |
| 131 | + EXPECT_TRUE((seqan3::reservible_container<seqan3::concatenated_sequences<std::string>>)); |
| 132 | + EXPECT_TRUE((seqan3::reservible_container<seqan3::concatenated_sequences<std::vector<char>>>)); |
| 133 | + |
| 134 | +- EXPECT_TRUE((seqan3::reservible_container<sdsl::bit_vector>)); |
| 135 | +- EXPECT_TRUE((seqan3::reservible_container<sdsl::int_vector<>>)); |
| 136 | +- EXPECT_TRUE((seqan3::reservible_container<sdsl::int_vector<13>>)); |
| 137 | +- EXPECT_TRUE((seqan3::reservible_container<sdsl::int_vector<64>>)); |
| 138 | ++ EXPECT_TRUE((seqan3::reservible_container<seqan3::contrib::sdsl::bit_vector>)); |
| 139 | ++ EXPECT_TRUE((seqan3::reservible_container<seqan3::contrib::sdsl::int_vector<>>)); |
| 140 | ++ EXPECT_TRUE((seqan3::reservible_container<seqan3::contrib::sdsl::int_vector<13>>)); |
| 141 | ++ EXPECT_TRUE((seqan3::reservible_container<seqan3::contrib::sdsl::int_vector<64>>)); |
| 142 | + EXPECT_TRUE((seqan3::reservible_container<seqan3::bitpacked_sequence<seqan3::dna4>>)); |
| 143 | + EXPECT_TRUE( |
| 144 | + (seqan3::reservible_container<seqan3::bitpacked_sequence<seqan3::qualified<seqan3::dna4, seqan3::phred42>>>)); |
| 145 | +diff --git a/test/unit/search/dream_index/interleaved_bloom_filter_test.cpp b/test/unit/search/dream_index/interleaved_bloom_filter_test.cpp |
| 146 | +index 71ba36238..a6c608ec6 100644 |
| 147 | +--- a/test/unit/search/dream_index/interleaved_bloom_filter_test.cpp |
| 148 | ++++ b/test/unit/search/dream_index/interleaved_bloom_filter_test.cpp |
| 149 | +@@ -350,7 +350,7 @@ TYPED_TEST(interleaved_bloom_filter_test, data_access) |
| 150 | + { |
| 151 | + seqan3::interleaved_bloom_filter ibf{seqan3::bin_count{1024u}, seqan3::bin_size{1024u}}; |
| 152 | + |
| 153 | +- EXPECT_LE(sdsl::size_in_mega_bytes(ibf.raw_data()), 1.0f); |
| 154 | ++ EXPECT_LE(seqan3::contrib::sdsl::size_in_mega_bytes(ibf.raw_data()), 1.0f); |
| 155 | + } |
| 156 | + |
| 157 | + TYPED_TEST(interleaved_bloom_filter_test, serialisation) |
| 158 | +diff --git a/test/unit/search/fm_index_cursor/fm_index_cursor_collection_test_template.hpp b/test/unit/search/fm_index_cursor/fm_index_cursor_collection_test_template.hpp |
| 159 | +index 5b80df314..4ef040186 100644 |
| 160 | +--- a/test/unit/search/fm_index_cursor/fm_index_cursor_collection_test_template.hpp |
| 161 | ++++ b/test/unit/search/fm_index_cursor/fm_index_cursor_collection_test_template.hpp |
| 162 | +@@ -17,13 +17,16 @@ |
| 163 | + |
| 164 | + #include "../helper.hpp" |
| 165 | + |
| 166 | +-using sdsl_byte_index_type = sdsl::csa_wt< |
| 167 | +- sdsl::wt_blcd<sdsl::bit_vector, sdsl::rank_support_v<>, sdsl::select_support_scan<>, sdsl::select_support_scan<0>>, |
| 168 | +- 16, |
| 169 | +- 10000000, |
| 170 | +- sdsl::sa_order_sa_sampling<>, |
| 171 | +- sdsl::isa_sampling<>, |
| 172 | +- sdsl::byte_alphabet>; |
| 173 | ++using sdsl_byte_index_type = |
| 174 | ++ seqan3::contrib::sdsl::csa_wt<seqan3::contrib::sdsl::wt_blcd<seqan3::contrib::sdsl::bit_vector, |
| 175 | ++ seqan3::contrib::sdsl::rank_support_v<>, |
| 176 | ++ seqan3::contrib::sdsl::select_support_scan<>, |
| 177 | ++ seqan3::contrib::sdsl::select_support_scan<0>>, |
| 178 | ++ 16, |
| 179 | ++ 10'000'000, |
| 180 | ++ seqan3::contrib::sdsl::sa_order_sa_sampling<>, |
| 181 | ++ seqan3::contrib::sdsl::isa_sampling<>, |
| 182 | ++ seqan3::contrib::sdsl::byte_alphabet>; |
| 183 | + |
| 184 | + template <typename T> |
| 185 | + struct fm_index_cursor_collection_test; |
| 186 | +diff --git a/test/unit/search/fm_index_cursor/fm_index_cursor_test_template.hpp b/test/unit/search/fm_index_cursor/fm_index_cursor_test_template.hpp |
| 187 | +index 8564b1df6..b11b1c985 100644 |
| 188 | +--- a/test/unit/search/fm_index_cursor/fm_index_cursor_test_template.hpp |
| 189 | ++++ b/test/unit/search/fm_index_cursor/fm_index_cursor_test_template.hpp |
| 190 | +@@ -16,13 +16,16 @@ |
| 191 | + |
| 192 | + #include "../helper.hpp" |
| 193 | + |
| 194 | +-using sdsl_byte_index_type = sdsl::csa_wt< |
| 195 | +- sdsl::wt_blcd<sdsl::bit_vector, sdsl::rank_support_v<>, sdsl::select_support_scan<>, sdsl::select_support_scan<0>>, |
| 196 | +- 16, |
| 197 | +- 10000000, |
| 198 | +- sdsl::sa_order_sa_sampling<>, |
| 199 | +- sdsl::isa_sampling<>, |
| 200 | +- sdsl::byte_alphabet>; |
| 201 | ++using sdsl_byte_index_type = |
| 202 | ++ seqan3::contrib::sdsl::csa_wt<seqan3::contrib::sdsl::wt_blcd<seqan3::contrib::sdsl::bit_vector, |
| 203 | ++ seqan3::contrib::sdsl::rank_support_v<>, |
| 204 | ++ seqan3::contrib::sdsl::select_support_scan<>, |
| 205 | ++ seqan3::contrib::sdsl::select_support_scan<0>>, |
| 206 | ++ 16, |
| 207 | ++ 10'000'000, |
| 208 | ++ seqan3::contrib::sdsl::sa_order_sa_sampling<>, |
| 209 | ++ seqan3::contrib::sdsl::isa_sampling<>, |
| 210 | ++ seqan3::contrib::sdsl::byte_alphabet>; |
| 211 | + |
| 212 | + using locate_result_t = std::vector<std::pair<uint64_t, uint64_t>>; |
| 213 | + |
| 214 | +diff --git a/test/unit/search/sdsl_index_test.cpp b/test/unit/search/sdsl_index_test.cpp |
| 215 | +index 29042c51b..2277cd624 100644 |
| 216 | +--- a/test/unit/search/sdsl_index_test.cpp |
| 217 | ++++ b/test/unit/search/sdsl_index_test.cpp |
| 218 | +@@ -9,7 +9,7 @@ |
| 219 | + |
| 220 | + #include <seqan3/search/fm_index/concept.hpp> |
| 221 | + |
| 222 | +-using namespace sdsl; |
| 223 | ++using namespace seqan3::contrib::sdsl; |
| 224 | + |
| 225 | + template <typename T> |
| 226 | + class sdsl_index_test : public ::testing::Test |
| 227 | +diff --git a/test/unit/utility/bloom_filter/bloom_filter_test.cpp b/test/unit/utility/bloom_filter/bloom_filter_test.cpp |
| 228 | +index 612683cf3..2133abd37 100644 |
| 229 | +--- a/test/unit/utility/bloom_filter/bloom_filter_test.cpp |
| 230 | ++++ b/test/unit/utility/bloom_filter/bloom_filter_test.cpp |
| 231 | +@@ -125,7 +125,7 @@ TYPED_TEST(bloom_filter_test, reset) |
| 232 | + TYPED_TEST(bloom_filter_test, data_access) |
| 233 | + { |
| 234 | + seqan3::bloom_filter bf{seqan3::bin_size{1024u}}; |
| 235 | +- EXPECT_LE(sdsl::size_in_mega_bytes(bf.raw_data()), 0.001f); |
| 236 | ++ EXPECT_LE(seqan3::contrib::sdsl::size_in_mega_bytes(bf.raw_data()), 0.001f); |
| 237 | + } |
| 238 | + |
| 239 | + TYPED_TEST(bloom_filter_test, serialisation) |
| 240 | +-- |
| 241 | +2.47.2 |
| 242 | + |
0 commit comments