Skip to content

Commit

Permalink
fix thread local variable hibf_config.
Browse files Browse the repository at this point in the history
  • Loading branch information
smehringer committed Dec 4, 2023
1 parent 749b037 commit 6b5b28c
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/layout/execute.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -225,11 +225,12 @@ int execute(chopper::configuration & config, std::vector<std::string> const & fi
seqan::hibf::concurrent_timer dp_algorithm_timer{};

// reset tmax to fit number of user bins in layout
config.hibf_config.tmax =
auto local_hibf_config = config.hibf_config; // every thread needs to set individual tmax
local_hibf_config.tmax =
chopper::next_multiple_of_64(static_cast<uint16_t>(std::ceil(std::sqrt(positions[i].size()))));

dp_algorithm_timer.start();
hibf_layouts[i] = seqan::hibf::layout::compute_layout(config.hibf_config,
hibf_layouts[i] = seqan::hibf::layout::compute_layout(local_hibf_config,
cardinalities,
sketches,
std::move(positions[i]),
Expand Down

0 comments on commit 6b5b28c

Please sign in to comment.