diff --git a/dlib/svm/structural_graph_labeling_trainer.h b/dlib/svm/structural_graph_labeling_trainer.h index 0259d568c..8f6cbc934 100644 --- a/dlib/svm/structural_graph_labeling_trainer.h +++ b/dlib/svm/structural_graph_labeling_trainer.h @@ -132,8 +132,14 @@ namespace dlib const std::vector& labels ) const { - // TODO // make sure requires clause is not broken + DLIB_ASSERT(is_graph_labeling_problem(samples, labels), + "\t void structural_graph_labeling_trainer::train()" + << "\n\t samples.size(): " << samples.size() + << "\n\t labels.size(): " << labels.size() + << "\n\t this: " << this + ); + structural_svm_graph_labeling_problem prob(samples, labels, num_threads);