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/>.
30 typedef float scalar_t;
33 #define ASSERT(x) if(!(x)) { \
34 std::cerr << "ASSERT FAILED IN " << __FILE__ << ":" << __LINE__ << endl; \
42 T **allocate_array(int a, int b) {
43 T *whole = new T[a * b];
44 T **array = new T *[a];
45 for(int k = 0; k < a; k++) {
53 void deallocate_array(T **array) {