source: trunk/yat/classifier/FeatureSelector.cc @ 1797

Last change on this file since 1797 was 1797, checked in by Peter, 13 years ago

updating copyright statements

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date ID
File size: 1.4 KB
RevLine 
[604]1// $Id$
2
[675]3/*
[1797]4  Copyright (C) 2006, 2007, 2008 Jari Häkkinen, Peter Johansson
[675]5
[1437]6  This file is part of the yat library, http://dev.thep.lu.se/yat
[675]7
8  The yat library is free software; you can redistribute it and/or
9  modify it under the terms of the GNU General Public License as
[1486]10  published by the Free Software Foundation; either version 3 of the
[675]11  License, or (at your option) any later version.
12
13  The yat library is distributed in the hope that it will be useful,
14  but WITHOUT ANY WARRANTY; without even the implied warranty of
15  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16  General Public License for more details.
17
18  You should have received a copy of the GNU General Public License
[1487]19  along with yat. If not, see <http://www.gnu.org/licenses/>.
[675]20*/
21
[604]22#include "FeatureSelector.h"
[624]23#include "MatrixLookup.h"
24#include "MatrixLookupWeighted.h"
[604]25
26#include <list>
27
28namespace theplu {
[680]29namespace yat {
[604]30namespace classifier {
31
32
33  FeatureSelector::FeatureSelector(size_t N, size_t first)
34    : first_(first), N_(N)
35  {
36  }
37
38
39  FeatureSelector::~FeatureSelector()
40  {
41  }
42
43
[1134]44  const utility::Index FeatureSelector::features(void) const
[720]45  {
46    return features_;
47  }
48
49
[1204]50  const MatrixLookup FeatureSelector::get(const MatrixLookup& matrix)
[604]51  {
[1204]52    return MatrixLookup(matrix, features_,true);
[604]53  }
54
[624]55
[1204]56  const MatrixLookupWeighted
[624]57  FeatureSelector::get(const MatrixLookupWeighted& matrix)
58  {
[1204]59    return MatrixLookupWeighted(matrix, features_, true);
[624]60  }
61
[680]62}}} // of namespace classifier, yat, and theplu
Note: See TracBrowser for help on using the repository browser.