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

Method dense_potts_problem

dlib/test/graph_cuts.cpp:40–49  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

38 public:
39
40 dense_potts_problem (
41 unsigned long num_nodes,
42 dlib::rand& rnd
43 )
44 {
45 factors1 = -7*(randm(num_nodes, 1, rnd)-0.5);
46 factors2 = make_symmetric(randm(num_nodes, num_nodes, rnd) > 0.5);
47 labels.set_size(num_nodes);
48 labels = FREE_NODE;
49 }
50
51 unsigned long number_of_nodes (
52 ) const { return factors1.nr(); }

Callers

nothing calls this directly

Calls 3

make_symmetricFunction · 0.85
randmFunction · 0.70
set_sizeMethod · 0.45

Tested by

no test coverage detected