3 * mtp is the ``Multi Tracked Paths'', an implementation of the
4 * k-shortest paths algorithm for multi-target tracking.
6 * Copyright (c) 2012 Idiap Research Institute, http://www.idiap.ch/
7 * Written by Francois Fleuret <francois.fleuret@idiap.ch>
9 * This file is part of mtp.
11 * mtp is free software: you can redistribute it and/or modify it
12 * under the terms of the GNU General Public License version 3 as
13 * published by the Free Software Foundation.
15 * mtp is distributed in the hope that it will be useful, but WITHOUT
16 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
17 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
18 * License for more details.
20 * You should have received a copy of the GNU General Public License
21 * along with selector. If not, see <http://www.gnu.org/licenses/>.
40 void update_positivized_lengths();
41 // It may happen that numerical errors in update_positivized_lengths
42 // make the resulting lengths negative, albeit very small. The
43 // following method force such length to zero, and print the
44 // correction when compiled in VERBOSE mode.
45 void force_positivized_lengths();
46 // Set the edge pred_edge_toward_source correspondingly to the path
47 // of shortest length. The current implementation is not Dijkstra's!
48 void find_shortest_path();
49 // Follows the path starting on edge e and returns its length. If
50 // nodes is non-null, stores in it the nodes met along the path.
51 int retrieve_one_path(Edge *e, Path *path);
52 // Returns if the graph is a DAG
55 Vertex **_front, **_new_front;
57 int _nb_vertices, _nb_edges;
58 Vertex *_source, *_sink;
65 // These variables are filled when retrieve_disjoint_paths is called
69 MTPGraph(int nb_vertices, int nb_edges, int *vertex_from, int *vertex_to,
70 int source, int sink);
74 void find_best_paths(scalar_t *lengths);
75 void retrieve_disjoint_paths();
77 void print(ostream *os);
78 void print_dot(ostream *os);