3 * mtp is the ``Multi Tracked Path'', an implementation of the
4 * k-shortest path 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/>.
34 int main(int argc, char **argv) {
37 cerr << argv[0] << " <tracker file>" << endl;
41 ifstream *in_tracker = new ifstream(argv[1]);
43 if(in_tracker->good()) {
45 Tracker *tracker = new Tracker();
47 tracker->read(in_tracker);
48 cout << "Read " << argv[1] << endl;
50 tracker->build_graph();
53 ofstream out_traj("result.trj");
54 tracker->write_trajectories(&out_traj);
55 cout << "Wrote result.trj" << endl;
57 ofstream out_dot("graph.dot");
58 tracker->print_graph_dot(&out_dot);
59 cout << "Wrote graph.dot" << endl;
65 cerr << "Can not open " << argv[1] << endl;