SHOGUN  v3.2.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Subset.h
Go to the documentation of this file.
00001 /*
00002  * This program is free software; you can redistribute it and/or modify
00003  * it under the terms of the GNU General Public License as published by
00004  * the Free Software Foundation; either version 3 of the License, or
00005  * (at your option) any later version.
00006  *
00007  * Written (W) 2011-2012 Heiko Strathmann
00008  * Copyright (C) 2011 Berlin Institute of Technology and Max-Planck-Society
00009  */
00010 
00011 #ifndef __SUBSET_H_
00012 #define __SUBSET_H_
00013 
00014 #include <shogun/lib/common.h>
00015 #include <shogun/base/SGObject.h>
00016 #include <shogun/mathematics/Math.h>
00017 #include <shogun/lib/SGVector.h>
00018 
00019 namespace shogun
00020 {
00022 class CSubset: public CSGObject
00023 {
00024     friend class CSubsetStack;
00025 
00026 public:
00028     CSubset();
00029 
00036     CSubset(SGVector<index_t> subset_idx);
00037 
00039     virtual ~CSubset();
00040 
00042     index_t get_size() const { return m_subset_idx.vlen; }
00043 
00045     inline const char* get_name() const { return "Subset"; }
00046 
00048     SGVector<index_t> get_subset_idx() const { return m_subset_idx; }
00049 
00050 private:
00051     void init();
00052 
00053 private:
00054     SGVector<index_t> m_subset_idx;
00055 };
00056 
00057 }
00058 #endif /* __SUBSET_H_ */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

SHOGUN Machine Learning Toolbox - Documentation