SHOGUN  v3.2.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
LinearStructuredOutputMachine.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) 2013 Thoralf Klein
00008  * Written (W) 2012 Fernando José Iglesias García
00009  * Copyright (C) 2012 Fernando José Iglesias García
00010  */
00011 
00012 #ifndef _LINEAR_STRUCTURED_OUTPUT_MACHINE__H__
00013 #define _LINEAR_STRUCTURED_OUTPUT_MACHINE__H__
00014 
00015 #include <shogun/features/Features.h>
00016 #include <shogun/machine/StructuredOutputMachine.h>
00017 
00018 namespace shogun
00019 {
00020 
00022 class CLinearStructuredOutputMachine : public CStructuredOutputMachine
00023 {
00024     public:
00026         CLinearStructuredOutputMachine();
00027 
00033         CLinearStructuredOutputMachine(CStructuredModel* model, CStructuredLabels* labs);
00034 
00036         virtual ~CLinearStructuredOutputMachine();
00037 
00042         void set_w(SGVector< float64_t > w);
00043 
00048         SGVector< float64_t > get_w() const;
00049 
00058         virtual CStructuredLabels* apply_structured(CFeatures* data = NULL);
00059 
00064         virtual void store_model_features();
00065 
00067         virtual const char* get_name() const
00068         {
00069             return "LinearStructuredOutputMachine";
00070         }
00071 
00072     private:
00074         void register_parameters();
00075 
00076     protected:
00078         SGVector< float64_t > m_w;
00079 
00080 }; /* class CLinearStructuredOutputMachine */
00081 
00082 } /* namespace shogun */
00083 
00084 #endif /* _LINEAR_STRUCTURED_OUTPUT_MACHINE__H__ */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

SHOGUN Machine Learning Toolbox - Documentation