Logo ROOT   6.30.04
Reference Guide
 All Namespaces Files Pages
SVKernelMatrix.h
Go to the documentation of this file.
1 // @(#)root/tmva $Id$
2 // Author: Andrzej Zemla
3 
4 /**********************************************************************************
5  * Project: TMVA - a Root-integrated toolkit for multivariate data analysis *
6  * Package: TMVA *
7  * Class : SVKernelMatrix *
8  * Web : http://tmva.sourceforge.net *
9  * *
10  * Description: *
11  * Kernel matrix for Support Vector Machine *
12  * *
13  * Authors (alphabetical): *
14  * Marcin Wolter <Marcin.Wolter@cern.ch> - IFJ PAN, Krakow, Poland *
15  * Andrzej Zemla <azemla@cern.ch> - IFJ PAN, Krakow, Poland *
16  * (IFJ PAN: Henryk Niewodniczanski Inst. Nucl. Physics, Krakow, Poland) *
17  * *
18  * Copyright (c) 2005: *
19  * CERN, Switzerland *
20  * MPI-K Heidelberg, Germany *
21  * PAN, Krakow, Poland *
22  * *
23  * Redistribution and use in source and binary forms, with or without *
24  * modification, are permitted according to the terms listed in LICENSE *
25  * (http://tmva.sourceforge.net/LICENSE) *
26  **********************************************************************************/
27 
28 #ifndef ROOT_TMVA_SVKernelMatrix
29 #define ROOT_TMVA_SVKernelMatrix
30 
31 #include "Rtypes.h"
32 
33 #include <vector>
34 
35 namespace TMVA {
36 
37  class SVEvent;
38  class SVKernelFunction;
39  class MsgLogger;
40 
41  class SVKernelMatrix {
42 
43  public:
44 
45  //constructors
46  SVKernelMatrix();
47  SVKernelMatrix( std::vector<TMVA::SVEvent*>*, SVKernelFunction* );
48 
49  //destructor
50  ~SVKernelMatrix();
51 
52  //functions
53  Float_t* GetLine ( UInt_t );
54  Float_t* GetColumn ( UInt_t col ) { return this->GetLine(col);}
55  Float_t GetElement( UInt_t i, UInt_t j );
56 
57  private:
58 
59  UInt_t fSize; // matrix size
60  SVKernelFunction* fKernelFunction; // kernel function
61  Float_t** fSVKernelMatrix; // kernel matrix
62 
63  mutable MsgLogger* fLogger; //! message logger
64  MsgLogger& Log() const { return *fLogger; }
65 
66  };
67 }
68 #endif