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

Function make_random_detections

dlib/test/learning_to_track.cpp:182–194  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

180
181 template <typename detection>
182 std::vector<detection> make_random_detections(long num_dets)
183 {
184 DLIB_CASSERT(num_dets <= num_objects,
185 "You can't ask for more detections than there are objects in our little simulation.");
186
187 std::vector<detection> dets(num_dets);
188 for (unsigned long i = 0; i < dets.size(); ++i)
189 {
190 dets[i] = sample_detection_from_sensor<detection>(i);
191 }
192 randomize_samples(dets, rnd);
193 return dets;
194 }
195
196// ----------------------------------------------------------------------------------------
197

Callers

nothing calls this directly

Calls 2

randomize_samplesFunction · 0.85
sizeMethod · 0.45

Tested by

no test coverage detected