libeblearn
|
00001 /*************************************************************************** 00002 * Copyright (C) 2008 by Yann LeCun and Pierre Sermanet * 00003 * yann@cs.nyu.edu, pierre.sermanet@gmail.com * 00004 * 00005 * Redistribution and use in source and binary forms, with or without 00006 * modification, are permitted provided that the following conditions are met: 00007 * * Redistributions of source code must retain the above copyright 00008 * notice, this list of conditions and the following disclaimer. 00009 * * Redistributions in binary form must reproduce the above copyright 00010 * notice, this list of conditions and the following disclaimer in the 00011 * documentation and/or other materials provided with the distribution. 00012 * * Redistribution under a license not approved by the Open Source 00013 * Initiative (http://www.opensource.org) must display the 00014 * following acknowledgement in all advertising material: 00015 * This product includes software developed at the Courant 00016 * Institute of Mathematical Sciences (http://cims.nyu.edu). 00017 * * The names of the authors may not be used to endorse or promote products 00018 * derived from this software without specific prior written permission. 00019 * 00020 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED 00021 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 00022 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 00023 * DISCLAIMED. IN NO EVENT SHALL ThE AUTHORS BE LIABLE FOR ANY 00024 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 00025 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 00026 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 00027 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 00028 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 00029 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 00030 ***************************************************************************/ 00031 00032 #ifndef EBL_UTILS_H_ 00033 #define EBL_UTILS_H_ 00034 00035 #include "ebl_defines.h" 00036 #include "libidx.h" 00037 00038 namespace ebl { 00039 00041 // Table functions 00042 00045 EXPORT idx<intg> full_table(intg a, intg b, intg a0 = 0, intg b0 = 0); 00049 EXPORT idx<intg> one2one_table(intg n); 00051 EXPORT idx<intg> concat_tables(idx<intg> &t0, idx<intg> &t1); 00054 EXPORT idx<intg> random_table(intg a, intg b, std::vector<intg> &fanin, 00055 intg a0 = 0, intg b0 = 0); 00060 EXPORT idx<intg> yuv_table0(intg yend, intg uend, intg vend, intg yuvend, 00061 intg uvend, intg &maxend); 00065 EXPORT idx<intg> uv_table0(intg uend, intg vend); 00071 EXPORT idx<intg> yuv_table1(intg yend, intg uend, intg vend, 00072 intg p0, intg p1, intg p2, intg fanin_y, 00073 intg fanin_yuv, intg fanin_uv); 00078 EXPORT idx<intg> stereo_table(intg lend, intg rend, intg lrend); 00084 EXPORT idx<intg> temporal3_table(intg end1, intg end2, intg end3, 00085 intg end12, intg end23, intg end123, 00086 intg &maxend); 00090 EXPORT bool check_table_duplicates(idx<intg> &table); 00091 00092 } // namespace ebl { 00093 00094 #endif /* EBL_UTILS_H_ */