23 auto builder = []<
class Direction>(
tag_t<Direction>) {
26 std::shared_ptr<collector_t> collector;
27 auto inner_solver = make_inner_solver<Solver<Direction>>(opts);
28 bool extra_stats =
false;
31 collector = std::make_shared<collector_t>();
32 inner_solver.set_progress_callback(
33 [collector](
const auto &progress_info) {
34 collector->update_iter(progress_info);
40 auto run = [solver{std::move(solver)},
46 return std::make_shared<AlpaqaSolverWrapperStats<config_t>>(
47 std::move(run), std::move(collector));
50 std::map<std::string_view, solver_builder_func> builders{
58 if (direction.empty())
60 auto builder_it = builders.find(direction);
61 if (builder_it != builders.end())
62 return builder_it->second(direction, opts);
64 throw std::invalid_argument(
65 "Unknown direction '" + std::string(direction) +
"'\n" +
66 " Available directions: " +