9 #ifndef META_CLASSIFY_ONE_VS_ONE_H_
10 #define META_CLASSIFY_ONE_VS_ONE_H_
42 template <
class Function>
43 one_vs_one(std::shared_ptr<index::forward_index> idx, Function&& create)
46 auto labels =
idx_->class_labels();
47 for (uint64_t i = 0; i < labels.size(); ++i)
49 for (uint64_t j = i + 1; j < labels.size(); ++j)
56 void train(
const std::vector<doc_id>& docs)
override;
58 class_label
classify(doc_id d_id)
override;
60 void reset()
override;
65 const static std::string
id;
77 std::unique_ptr<classifier>
79 std::shared_ptr<index::forward_index>);