diff --git a/include/hibf/layout/execute.hpp b/include/hibf/layout/execute.hpp deleted file mode 100644 index 1790affd..00000000 --- a/include/hibf/layout/execute.hpp +++ /dev/null @@ -1,13 +0,0 @@ -#pragma once - -#include // for size_t - -#include // for config -#include // for data_store - -namespace seqan::hibf::layout -{ - -size_t execute(config const &, data_store &); - -} // namespace seqan::hibf::layout diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 8f0a336d..7351052e 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -3,7 +3,6 @@ set (HIBF_SOURCE_FILES config.cpp layout/simple_binning.cpp layout/layout.cpp - layout/execute.cpp layout/compute_fpr_correction.cpp layout/compute_layout.cpp layout/graph.cpp diff --git a/src/layout/compute_layout.cpp b/src/layout/compute_layout.cpp index 9369baf0..455bff90 100644 --- a/src/layout/compute_layout.cpp +++ b/src/layout/compute_layout.cpp @@ -7,14 +7,15 @@ #include // for addressof #include // for vector -#include // for config -#include // for unordered_flat_set -#include // for compute_layout -#include // for data_store -#include // for execute -#include // for layout -#include // for estimate_kmer_counts -#include // for hyperloglog +#include // for config +#include // for unordered_flat_set +#include // for compute_fpr_correction +#include // for compute_layout +#include // for data_store +#include // for hierarchical_binning +#include // for layout +#include // for estimate_kmer_counts +#include // for hyperloglog namespace seqan::hibf::layout { @@ -55,9 +56,11 @@ compute_layout(config const & config, std::vector & kmer_counts, std::ve .hibf_layout = &resulting_layout, .kmer_counts = std::addressof(kmer_counts), .sketches = std::addressof(sketches)}; + store.fpr_correction = compute_fpr_correction({.fpr = config.maximum_false_positive_rate, + .hash_count = config.number_of_hash_functions, + .t_max = config.tmax}); - size_t const max_hibf_id = seqan::hibf::layout::execute(config, store); - store.hibf_layout->top_level_max_bin_id = max_hibf_id; + store.hibf_layout->top_level_max_bin_id = seqan::hibf::layout::hierarchical_binning{store, config}.execute(); // sort records ascending by the number of bin indices (corresponds to the IBF levels) // GCOVR_EXCL_START diff --git a/src/layout/execute.cpp b/src/layout/execute.cpp deleted file mode 100644 index ea6abb77..00000000 --- a/src/layout/execute.cpp +++ /dev/null @@ -1,21 +0,0 @@ -#include // for vector - -#include // for config -#include // for compute_fpr_correction -#include // for data_store -#include // for execute -#include // for hierarchical_binning - -namespace seqan::hibf::layout -{ - -size_t execute(seqan::hibf::config const & config, seqan::hibf::layout::data_store & data) -{ - data.fpr_correction = compute_fpr_correction({.fpr = config.maximum_false_positive_rate, // prevent clang-format - .hash_count = config.number_of_hash_functions, - .t_max = config.tmax}); - - return seqan::hibf::layout::hierarchical_binning{data, config}.execute(); -} - -} // namespace seqan::hibf::layout