OpenCV-2.0.0.tar.bz2


OpenCV-2.0.0.tar.bz2 计算机视觉处理的库
资源截图
代码片段和文件信息
/***********************************************************************
 * Software License Agreement (BSD License)
 *
 * Copyright 2008-2009  Marius Muja (mariusm@cs.ubc.ca). All rights reserved.
 * Copyright 2008-2009  David G. Lowe (lowe@cs.ubc.ca). All rights reserved.
 *
 * THE BSD LICENSE
 *
 * Redistribution and use in source and binary forms with or without
 * modification are permitted provided that the following conditions
 * are met:
 *
 * 1. Redistributions of source code must retain the above copyright
 *    notice this list of conditions and the following disclaimer.
 * 2. Redistributions in binary form must reproduce the above copyright
 *    notice this list of conditions and the following disclaimer in the
 *    documentation and/or other materials provided with the distribution.
 *
 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ‘‘AS IS‘‘ AND ANY EXPRESS OR
 * IMPLIED WARRANTIES INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES
 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT INDIRECT
 * INCIDENTAL SPECIAL EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING BUT
 * NOT LIMITED TO PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE
 * DATA OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
 * THEORY OF LIABILITY WHETHER IN CONTRACT STRICT LIABILITY OR TORT
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
 * THIS SOFTWARE EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 *************************************************************************/

#include 
#include 
#include “flann.h“
#include “timer.h“
#include “common.h“
#include “logger.h“
#include “index_testing.h“
#include “saving.h“
#include “object_factory.h“
// index types
#include “kdtree_index.h“
#include “kmeans_index.h“
#include “composite_index.h“
#include “linear_index.h“
#include “autotuned_index.h“

#include 
using namespace std;



#include “flann.h“

#ifdef WIN32
#define EXPORTED extern “C“ __declspec(dllexport)
#else
#define EXPORTED extern “C“
#endif


namespace flann
{

typedef objectFactory ParamsFactory;


IndexParams* IndexParams::createFromParameters(const FLANNParameters& p)
{
IndexParams* params = ParamsFactory::instance().create(p.algorithm);
params->fromParameters(p);

return params;
}

NNIndex* LinearIndexParams::createIndex(const Matrix& dataset) const
{
return new LinearIndex(dataset *this);
}


NNIndex* KDTreeIndexParams::createIndex(const Matrix& dataset) const
{
return new KDTreeIndex(dataset *this);
}

NNIndex* KMeansIndexParams::createIndex(const Matrix& dataset) const
{
return new KMeansIndex(dataset *this);
}


NNIndex* CompositeIndexParams::createIndex(const Matrix& dataset) const
{
return new CompositeIndex(dataset *this);
}


NNIndex* AutotunedIndexParams::createIndex(const Matrix& dataset) const

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容, 请发送邮件举报,一经查实,本站将立刻删除。

发表评论

评论列表(条)