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

Function scale_by

dlib/svm/sparse_vector.h:407–416  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

405
406 template <typename T, typename U>
407 typename disable_if<is_matrix<T>,void>::type scale_by (
408 T& a,
409 const U& value
410 )
411 {
412 for (typename T::iterator i = a.begin(); i != a.end(); ++i)
413 {
414 i->second *= value;
415 }
416 }
417
418 template <typename T, typename U>
419 typename enable_if<is_matrix<T>,void>::type scale_by (

Callers 1

get_distance_functionMethod · 0.85

Calls 2

beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected