MCPcopy Create free account
hub / github.com/davisking/dlib / test_shape_predictor_with_images

Function test_shape_predictor_with_images

tools/python/src/shape_predictor.h:236–252  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

234
235 template <typename image_array>
236 inline double test_shape_predictor_with_images (
237 image_array& images,
238 std::vector<std::vector<full_object_detection> >& detections,
239 std::vector<std::vector<double> >& scales,
240 const shape_predictor& predictor
241 )
242 {
243 if (images.size() != detections.size())
244 throw error("The list of images must have the same length as the list of detections.");
245 if (scales.size() > 0 && scales.size() != images.size())
246 throw error("The list of scales must have the same length as the list of detections.");
247
248 if (scales.size() > 0)
249 return test_shape_predictor(predictor, images, detections, scales);
250 else
251 return test_shape_predictor(predictor, images, detections);
252 }
253
254 inline double test_shape_predictor_py (
255 const std::string& dataset_filename,

Callers 2

test_shape_predictor_pyFunction · 0.85

Calls 3

errorClass · 0.85
test_shape_predictorFunction · 0.85
sizeMethod · 0.45

Tested by

no test coverage detected