Logo ROOT   6.30.04
Reference Guide
 All Namespaces Files Pages
TMLPAnalyzer.h
Go to the documentation of this file.
1 // @(#)root/mlp:$Id$
2 // Author: Christophe.Delaere@cern.ch 25/04/04
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2003, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 #ifndef ROOT_TMLPAnalyzer
13 #define ROOT_TMLPAnalyzer
14 
15 
16 #include "TObject.h"
17 
18 class TTree;
19 class TNeuron;
20 class TSynapse;
21 class TMultiLayerPerceptron;
22 class TProfile;
23 class THStack;
24 
25 class TMLPAnalyzer : public TObject {
26 
27 private:
28  TMultiLayerPerceptron *fNetwork;
29  TTree *fAnalysisTree;
30  TTree *fIOTree;
31 
32 protected:
33  Int_t GetLayers();
34  Int_t GetNeurons(Int_t layer);
35  TString GetNeuronFormula(Int_t idx);
36  const char* GetInputNeuronTitle(Int_t in);
37  const char* GetOutputNeuronTitle(Int_t out);
38 
39 public:
40  TMLPAnalyzer(TMultiLayerPerceptron& net):
41  fNetwork(&net), fAnalysisTree(0), fIOTree(0) {}
42  TMLPAnalyzer(TMultiLayerPerceptron* net):
43  fNetwork(net), fAnalysisTree(0), fIOTree(0) {}
44  virtual ~TMLPAnalyzer();
45  void DrawNetwork(Int_t neuron, const char* signal, const char* bg);
46  void DrawDInput(Int_t i);
47  void DrawDInputs();
48  TProfile* DrawTruthDeviation(Int_t outnode=0, Option_t *option="");
49  THStack* DrawTruthDeviations(Option_t *option="");
50  TProfile* DrawTruthDeviationInOut(Int_t innode, Int_t outnode=0,
51  Option_t *option="");
52  THStack* DrawTruthDeviationInsOut(Int_t outnode=0, Option_t *option="");
53 
54  void CheckNetwork();
55  void GatherInformations();
56  TTree* GetIOTree() const { return fIOTree;}
57 
58  ClassDef(TMLPAnalyzer, 0) // A simple analysis class for MLP
59 };
60 
61 #endif