ROOT  6.07/01
Reference Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
network.cxx
Go to the documentation of this file.
1 #include "TMVA/network.h"
2 #include <iostream>
3 
4 #include "TArrow.h"
5 #include "TEllipse.h"
6 #include "TPaveLabel.h"
7 #include "TCanvas.h"
8 #include "TH2F.h"
9 #include "TFile.h"
10 #include "TString.h"
11 #include "TDirectory.h"
12 #include "TKey.h"
13 #include "TText.h"
14 
15 using std::cout;
16 using std::endl;
17 
18 
19 // this macro prints out a neural network generated by MethodMLP graphically
20 // @author: Matt Jachowski, jachowski@stanford.edu
21 
22 TFile* Network_GFile = 0;
23 
24 static Int_t c_DarkBackground = TColor::GetColor( "#6e7a85" );
25 
26 
28 
29 void TMVA::draw_network( TFile* f, TDirectory* d, const TString& hName,
30  Bool_t movieMode , const TString& epoch )
31 {
32  Bool_t __PRINT_LOGO__ = kTRUE;
33  Network_GFile = f;
34 
35  MovieMode = movieMode;
36  if (MovieMode) c_DarkBackground = TColor::GetColor( "#707F7F" );
37 
38  // create canvas
39  TStyle* TMVAStyle = gROOT->GetStyle("TMVA"); // the TMVA style
40  Int_t canvasColor = TMVAStyle->GetCanvasColor(); // backup
41  TMVAStyle->SetCanvasColor( c_DarkBackground );
42 
43  Int_t titleFillColor = TMVAStyle->GetTitleFillColor();
44  Int_t titleTextColor = TMVAStyle->GetTitleTextColor();
45  Int_t borderSize = TMVAStyle->GetTitleBorderSize();
46 
47  TMVAStyle->SetTitleFillColor( c_DarkBackground );
48  TMVAStyle->SetTitleTextColor( TColor::GetColor( "#FFFFFF" ) );
49  TMVAStyle->SetTitleBorderSize( 0 );
50 
51  static Int_t icanvas = -1;
52  Int_t ixc = 100 + (icanvas)*40;
53  Int_t iyc = 0 + (icanvas+1)*20;
54  if (MovieMode) ixc = iyc = 0;
55  TString canvasnumber = Form( "c%i", icanvas );
56  TString canvastitle = Form("Neural Network Layout for: %s", d->GetName());
57  TCanvas* c = new TCanvas( canvasnumber, canvastitle,
58  ixc, 0 + (icanvas+1)*20, 1000, 650 );
59  icanvas++;
60  TIter next = d->GetListOfKeys();
61  TKey *key( 0 );
62  Int_t numHists = 0;
63 
64  // loop over all histograms with hName in name again
65  next.Reset();
66  Double_t maxWeight = 0;
67  // find max weight
68  while ((key = (TKey*)next())) {
69 
70  TClass *cl = gROOT->GetClass(key->GetClassName());
71  if (!cl->InheritsFrom("TH2F")) continue;
72 
73  TH2F* h = (TH2F*)key->ReadObj();
74  if (!h) {
75  cout << "Big troubles in \"draw_network\" (1)" << endl;
76  exit(1);
77  }
78  if (TString(h->GetName()).Contains( hName )){
79  numHists++;
80 
81  Int_t n1 = h->GetNbinsX();
82  Int_t n2 = h->GetNbinsY();
83  for (Int_t i = 0; i < n1; i++) {
84  for (Int_t j = 0; j < n2; j++) {
85  Double_t weight = TMath::Abs(h->GetBinContent(i+1, j+1));
86  if (maxWeight < weight) maxWeight = weight;
87  }
88  }
89  }
90  }
91  if (numHists == 0) {
92  cout << "Error: could not find histograms" << endl;
93  //exit(1);
94  }
95 
96  // draw network
97  next.Reset();
98  //cout << "check4a" << endl;
99 
100  Int_t count = 0;
101  while ((key = (TKey*)next())) {
102  //cout << "check4b" << endl;
103 
104  TClass *cl = gROOT->GetClass(key->GetClassName());
105  if (!cl->InheritsFrom("TH2F")) continue;
106  //cout << "check4c" << endl;
107 
108  TH2F* h = (TH2F*)key->ReadObj();
109  //cout << (h->GetName()) << endl;
110  if (!h) {
111  cout << "Big troubles in \"draw_network\" (2)" << endl;
112  exit(1);
113  }
114  //cout << (h->GetName()) << endl;
115  if (TString(h->GetName()).Contains( hName )) {
116  //cout << (h->GetName()) << endl;
117  draw_layer(c, h, count++, numHists+1, maxWeight);
118  }
119  //cout << "check4d" << endl;
120 
121  }
122  draw_layer_labels(numHists+1);
123 
124  // add epoch
125  if (MovieMode) {
126  TText* t = new TText();
127  t->SetTextSize( 0.04 );
128  t->SetTextColor( 0 );
129  t->SetTextAlign( 31 );
130  t->DrawTextNDC( 1 - c->GetRightMargin(), 1 - c->GetTopMargin() - 0.033,
131  Form( "Epoch: %s", epoch.Data() ) );
132  }
133 
134  // ============================================================
135  if (__PRINT_LOGO__) TMVAGlob::plot_logo();
136  // ============================================================
137 
138  c->Update();
139  if (MovieMode) {
140  // save to file
141  TString dirname = "movieplots";
142  TString foutname = dirname + "/" + hName;
143  foutname.Resize( foutname.Length()-5 );
144  foutname.ReplaceAll("epochmonitoring___","");
145  foutname += ".gif";
146 
147  cout << "storing file: " << foutname << endl;
148  c->Print(foutname);
149  c->Clear();
150  delete c;
151  }
152  else {
153  TString fname = "plots/network";
154  TMVAGlob::imgconv( c, fname );
155  }
156 
157  // reset global style changes so that it does not affect other plots
158  TMVAStyle->SetCanvasColor ( canvasColor );
159  TMVAStyle->SetTitleFillColor ( titleFillColor );
160  TMVAStyle->SetTitleTextColor ( titleTextColor );
161  TMVAStyle->SetTitleBorderSize( borderSize );
162 
163 }
164 
166 {
167  const Double_t LABEL_HEIGHT = 0.032;
168  const Double_t LABEL_WIDTH = 0.20;
169  Double_t effWidth = 0.8*(1.0-LABEL_WIDTH)/nLayers;
170  Double_t height = 0.8*LABEL_HEIGHT;
171  Double_t margY = LABEL_HEIGHT - height;
172 
173  for (Int_t i = 0; i < nLayers; i++) {
174  TString label = Form("Layer %i", i);
175  if (i == nLayers-1) label = "Output layer";
176  Double_t cx = i*(1.0-LABEL_WIDTH)/nLayers+1.0/(2.0*nLayers)+LABEL_WIDTH;
177  Double_t x1 = cx-0.8*effWidth/2.0;
178  Double_t x2 = cx+0.8*effWidth/2.0;
179  Double_t y1 = margY;
180  Double_t y2 = margY + height;
181 
182  TPaveLabel *p = new TPaveLabel(x1, y1, x2, y2, label+"", "br");
185  p->SetFillStyle(1001);
186  p->SetBorderSize( 0 );
187  p->Draw();
188  }
189 }
190 
192  Double_t rad, Double_t layerWidth)
193 {
194  const Double_t LABEL_HEIGHT = 0.04;
195  const Double_t LABEL_WIDTH = 0.20;
196  Double_t width = LABEL_WIDTH + (layerWidth-4*rad);
197  Double_t margX = 0.01;
198  Double_t effHeight = 0.8*LABEL_HEIGHT;
199 
200  TString *varNames = get_var_names(nInputs);
201  if (varNames == 0) exit(1);
202 
203  TString input;
204 
205  for (Int_t i = 0; i < nInputs; i++) {
206  if (i != nInputs-1) input = varNames[i];
207  else input = "Bias node";
208  Double_t x = margX + width;
209  Double_t y = cy[i] - effHeight;
210 
211  TText* t = new TText();
213  t->SetTextAlign(31);
214  t->SetTextSize(LABEL_HEIGHT);
215  if (i == nInputs-1) t->SetTextColor( TColor::GetColor( "#AFDCEC" ) );
216  t->DrawText( x, y+0.018, input + " :");
217  }
218 
219  delete[] varNames;
220 }
221 
223 {
224  const TString directories[6] = { "InputVariables_NoTransform",
225  "InputVariables_DecorrTransform",
226  "InputVariables_PCATransform",
227  "InputVariables_Id",
228  "InputVariables_Norm",
229  "InputVariables_Deco"};
230 
231  TDirectory* dir = 0;
232  for (Int_t i=0; i<6; i++) {
233  dir = (TDirectory*)Network_GFile->Get( directories[i] );
234  if (dir != 0) break;
235  }
236  if (dir==0) {
237  cout << "*** Big troubles in macro \"network.cxx\": could not find directory for input variables, "
238  << "and hence could not determine variable names --> abort" << endl;
239  return 0;
240  }
241  dir->cd();
242 
243  TString* vars = new TString[nVars];
244  Int_t ivar = 0;
245 
246  // loop over all objects in directory
247  TIter next(dir->GetListOfKeys());
248  TKey* key = 0;
249  while ((key = (TKey*)next())) {
250  if (key->GetCycle() != 1) continue;
251 
252  if (!TString(key->GetName()).Contains("__S") &&
253  !TString(key->GetName()).Contains("__r") &&
254  !TString(key->GetName()).Contains("Regression"))
255  continue;
256  if (TString(key->GetName()).Contains("target"))
257  continue;
258 
259  // make sure, that we only look at histograms
260  TClass *cl = gROOT->GetClass(key->GetClassName());
261  if (!cl->InheritsFrom("TH1")) continue;
262  TH1 *sig = (TH1*)key->ReadObj();
263  TString hname = sig->GetTitle();
264 
265  vars[ivar] = hname; ivar++;
266 
267  if (ivar > nVars-1) break;
268  }
269 
270  if (ivar != nVars-1) { // bias layer and targets are also in nVars counts
271  cout << "*** Troubles in \"network.cxx\": did not reproduce correct number of "
272  << "input variables: " << ivar << " != " << nVars << endl;
273  }
274 
275  return vars;
276 }
277 
279  Double_t radx, Double_t rady, Int_t whichActivation)
280 {
281  TImage *activation = NULL;
282 
283  switch (whichActivation) {
284  case 0:
285  activation = TMVA::TMVAGlob::findImage("sigmoid-small.png");
286  break;
287  case 1:
288  activation = TMVA::TMVAGlob::findImage("line-small.png");
289  break;
290  default:
291  cout << "Activation index " << whichActivation << " is not known." << endl;
292  cout << "You messed up or you need to modify network.cxx to introduce a new "
293  << "activation function (and image) corresponding to this index" << endl;
294  }
295 
296  if (activation == NULL) {
297  cout << "Could not create an image... exit" << endl;
298  return;
299  }
300 
301  activation->SetConstRatio(kFALSE);
302 
303  radx *= 0.7;
304  rady *= 0.7;
305  TString name = Form("activation%f%f", cx, cy);
306  TPad* p = new TPad(name+"", name+"", cx-radx, cy-rady, cx+radx, cy+rady);
307 
308  p->Draw();
309  p->cd();
310 
311  activation->Draw();
312  c->cd();
313 }
314 
316  Int_t nLayers, Double_t maxWeight)
317 {
318  const Double_t MAX_NEURONS_NICE = 12;
319  const Double_t LABEL_HEIGHT = 0.03;
320  const Double_t LABEL_WIDTH = 0.20;
321  Double_t ratio = ((Double_t)(c->GetWindowHeight())) / c->GetWindowWidth();
322  Double_t rad, cx1, *cy1, cx2, *cy2;
323 
324  // this is the smallest radius that will still display the activation images
325  rad = 0.04*650/c->GetWindowHeight();
326 
327  Int_t nNeurons1 = h->GetNbinsX();
328  cx1 = iHist*(1.0-LABEL_WIDTH)/nLayers + 1.0/(2.0*nLayers) + LABEL_WIDTH;
329  cy1 = new Double_t[nNeurons1];
330 
331  Int_t nNeurons2 = h->GetNbinsY();
332  cx2 = (iHist+1)*(1.0-LABEL_WIDTH)/nLayers + 1.0/(2.0*nLayers) + LABEL_WIDTH;
333  cy2 = new Double_t[nNeurons2];
334 
335  Double_t effRad1 = rad;
336  if (nNeurons1 > MAX_NEURONS_NICE)
337  effRad1 = 0.8*(1.0-LABEL_HEIGHT)/(2.0*nNeurons1);
338 
339  for (Int_t i = 0; i < nNeurons1; i++) {
340  cy1[nNeurons1-i-1] = i*(1.0-LABEL_HEIGHT)/nNeurons1 + 1.0/(2.0*nNeurons1) + LABEL_HEIGHT;
341 
342  if (iHist == 0) {
343 
344  TEllipse *ellipse = new TEllipse( cx1, cy1[nNeurons1-i-1],
345  effRad1*ratio, effRad1, 0, 360, 0 );
346  ellipse->SetFillColor(TColor::GetColor( "#fffffd" ));
347  ellipse->SetFillStyle(1001);
348  ellipse->Draw();
349 
350  if (i == 0) ellipse->SetLineColor(9);
351 
352  if (nNeurons1 > MAX_NEURONS_NICE) continue;
353 
354  Int_t whichActivation = 0;
355  if (iHist==0 || iHist==nLayers-1 || i==0) whichActivation = 1;
356  draw_activation(c, cx1, cy1[nNeurons1-i-1],
357  rad*ratio, rad, whichActivation);
358  }
359  }
360 
361  if (iHist == 0) draw_input_labels(nNeurons1, cy1, rad, (1.0-LABEL_WIDTH)/nLayers);
362 
363  Double_t effRad2 = rad;
364  if (nNeurons2 > MAX_NEURONS_NICE)
365  effRad2 = 0.8*(1.0-LABEL_HEIGHT)/(2.0*nNeurons2);
366 
367  for (Int_t i = 0; i < nNeurons2; i++) {
368  cy2[nNeurons2-i-1] = i*(1.0-LABEL_HEIGHT)/nNeurons2 + 1.0/(2.0*nNeurons2) + LABEL_HEIGHT;
369 
370  TEllipse *ellipse =
371  new TEllipse(cx2, cy2[nNeurons2-i-1], effRad2*ratio, effRad2, 0, 360, 0);
372  ellipse->SetFillColor(TColor::GetColor( "#fffffd" ));
373  ellipse->SetFillStyle(1001);
374  ellipse->Draw();
375 
376  if (i == 0 && nNeurons2 > 1) ellipse->SetLineColor(9);
377 
378  if (nNeurons2 > MAX_NEURONS_NICE) continue;
379 
380  Int_t whichActivation = 0;
381  if (iHist+1==0 || iHist+1==nLayers-1 || i==0) whichActivation = 1;
382  draw_activation(c, cx2, cy2[nNeurons2-i-1], rad*ratio, rad, whichActivation);
383  }
384 
385  for (Int_t i = 0; i < nNeurons1; i++) {
386  for (Int_t j = 0; j < nNeurons2; j++) {
387  draw_synapse(cx1, cy1[i], cx2, cy2[j], effRad1*ratio, effRad2*ratio,
388  h->GetBinContent(i+1, j+1)/maxWeight);
389  }
390  }
391 
392  delete [] cy1;
393  delete [] cy2;
394 }
395 
397  Double_t rad1, Double_t rad2, Double_t weightNormed)
398 {
399  const Double_t TIP_SIZE = 0.01;
400  const Double_t MAX_WEIGHT = 8;
401  const Double_t MAX_COLOR = 100; // red
402  const Double_t MIN_COLOR = 60; // blue
403 
404  if (weightNormed == 0) return;
405 
406  // gStyle->SetPalette(100, NULL);
407 
408  TArrow *arrow = new TArrow(cx1+rad1, cy1, cx2-rad2, cy2, TIP_SIZE, ">");
409  arrow->SetFillColor(1);
410  arrow->SetFillStyle(1001);
411  arrow->SetLineWidth((Int_t)(TMath::Abs(weightNormed)*MAX_WEIGHT+0.5));
412  arrow->SetLineColor((Int_t)((weightNormed+1.0)/2.0*(MAX_COLOR-MIN_COLOR)+MIN_COLOR+0.5));
413  arrow->Draw();
414 }
415 
416 // input: - Input file (result from TMVA),
417 // - use of TMVA plotting TStyle
418 void TMVA::network( TString fin , Bool_t useTMVAStyle )
419 {
420  // set style and remove existing canvas'
421  TMVAGlob::Initialize( useTMVAStyle );
422 
423  // checks if file with name "fin" is already open, and if not opens one
424  TFile* file = TMVAGlob::OpenFile( fin );
425  TIter next(file->GetListOfKeys());
426  TKey *key(0);
427  while( (key = (TKey*)next()) ) {
428  if (!TString(key->GetName()).BeginsWith("Method_MLP")) continue;
429  if( ! gROOT->GetClass(key->GetClassName())->InheritsFrom("TDirectory") ) continue;
430 
431  cout << "--- Found directory: " << ((TDirectory*)key->ReadObj())->GetName() << endl;
432 
433  TDirectory* mDir = (TDirectory*)key->ReadObj();
434 
435  TIter keyIt(mDir->GetListOfKeys());
436  TKey *titkey;
437  while((titkey = (TKey*)keyIt())) {
438  if( ! gROOT->GetClass(titkey->GetClassName())->InheritsFrom("TDirectory") ) continue;
439 
440  TDirectory* dir = (TDirectory *)titkey->ReadObj();
441  dir->cd();
442  TList titles;
443  UInt_t ni = TMVAGlob::GetListOfTitles( dir, titles );
444  if (ni==0) {
445  cout << "No titles found for Method_MLP" << endl;
446  return;
447  }
448  draw_network( file, dir );
449  }
450  }
451 
452  return;
453 }
454 
void network(TString fin="TMVA.root", Bool_t useTMVAStyle=kTRUE)
Definition: network.cxx:418
virtual const char * GetTitle() const
Returns title of object.
Definition: TNamed.h:52
TString * get_var_names(Int_t nVars)
Definition: network.cxx:222
virtual void SetLineWidth(Width_t lwidth)
Definition: TAttLine.h:57
void imgconv(TCanvas *c, const TString &fname)
Definition: tmvaglob.cxx:212
virtual TList * GetListOfKeys() const
Definition: TDirectory.h:158
ClassImp(TSeqCollection) Int_t TSeqCollection TIter next(this)
Return index of object in collection.
Ssiz_t Length() const
Definition: TString.h:390
return c
static Int_t c_DarkBackground
Definition: network.cxx:24
TString & ReplaceAll(const TString &s1, const TString &s2)
Definition: TString.h:635
R__EXTERN TStyle * gStyle
Definition: TStyle.h:423
TFile * OpenFile(const TString &fin)
Definition: tmvaglob.cxx:192
virtual TList * GetListOfKeys() const
Color_t GetTitleFillColor() const
Definition: TStyle.h:279
TH1 * h
Definition: legend2.C:5
virtual void SetConstRatio(Bool_t constRatio=kTRUE)
Set (constRatio = kTRUE) or unset (constRadio = kFALSE) the ratio flag.
Definition: TAttImage.cxx:641
A ROOT file is a suite of consecutive data records (TKey instances) with a well defined format...
Definition: TFile.h:45
TVirtualPad * cd(Int_t subpadnumber=0)
Set current canvas & pad.
Definition: TCanvas.cxx:659
virtual TObject * Get(const char *namecycle)
Return pointer to object identified by namecycle.
#define gROOT
Definition: TROOT.h:344
Basic string class.
Definition: TString.h:137
virtual const char * GetClassName() const
Definition: TKey.h:77
int Int_t
Definition: RtypesCore.h:41
bool Bool_t
Definition: RtypesCore.h:59
const Bool_t kFALSE
Definition: Rtypes.h:92
virtual void Draw(Option_t *option="")
Default Draw method for all objects.
Definition: TObject.cxx:254
virtual void SetFillStyle(Style_t fstyle)
Definition: TAttFill.h:52
An abstract interface to image processing library.
Definition: TImage.h:45
virtual Int_t GetNbinsX() const
Definition: TH1.h:296
UInt_t GetWindowHeight() const
Definition: TCanvas.h:185
void draw_activation(TCanvas *c, Double_t cx, Double_t cy, Double_t radx, Double_t rady, Int_t whichActivation)
Definition: network.cxx:278
Short_t Abs(Short_t d)
Definition: TMathBase.h:110
void Reset()
Definition: TCollection.h:161
TFile * f
Width_t GetTitleBorderSize() const
Definition: TStyle.h:283
void SetCanvasColor(Color_t color=19)
Definition: TStyle.h:339
const char * Data() const
Definition: TString.h:349
void SetTitleBorderSize(Width_t size=2)
Definition: TStyle.h:402
TVirtualPad * cd(Int_t subpadnumber=0)
Set Current pad.
Definition: TPad.cxx:514
static const double x2[5]
Double_t x[n]
Definition: legend1.C:17
TArrow * arrow
Color_t GetTitleTextColor() const
Definition: TStyle.h:280
virtual TText * DrawTextNDC(Double_t x, Double_t y, const char *text)
Draw this text with new coordinates in NDC.
Definition: TText.cxx:197
virtual void Draw(Option_t *option="")
Draw this arrow with its current attributes.
Definition: TArrow.cxx:121
int d
Definition: tornado.py:11
void Clear()
Clear string without changing its capacity.
Definition: TString.cxx:1126
bool BeginsWith(const std::string &theString, const std::string &theSubstring)
Base class for several text objects.
Definition: TText.h:42
void draw_input_labels(Int_t nInputs, Double_t *cy, Double_t rad, Double_t layerWidth)
Definition: network.cxx:191
void SetTitleTextColor(Color_t color=1)
Definition: TStyle.h:399
Book space in a file, create I/O buffers, to fill them, (un)compress them.
Definition: TKey.h:30
virtual void Draw(Option_t *option="")
Draw Pad in Current pad (re-parent pad if necessary).
Definition: TPad.cxx:1192
virtual void Draw(Option_t *option="")
Draw this ellipse with its current attributes.
Definition: TEllipse.cxx:167
virtual void SetTextAlign(Short_t align=11)
Definition: TAttText.h:55
virtual Double_t GetBinContent(Int_t bin) const
Return content of bin number bin.
Definition: TH2.h:90
A doubly linked list.
Definition: TList.h:47
A Pave (see TPave) with a text centered in the Pave.
Definition: TPaveLabel.h:32
TStyle objects may be created to define special styles.
Definition: TStyle.h:52
virtual void SetLineColor(Color_t lcolor)
Definition: TAttLine.h:54
TThread * t[5]
Definition: threadsh1.C:13
#define MAX_COLOR
Definition: TGHtml.cxx:1609
void draw_network(TFile *f, TDirectory *d, const TString &hName="weights_hist", Bool_t movieMode=kFALSE, const TString &epoch="")
Definition: network.cxx:29
void Initialize(Bool_t useTMVAStyle=kTRUE)
Definition: tmvaglob.cxx:176
virtual void SetFillColor(Color_t fcolor)
Definition: TAttFill.h:50
2-D histogram with a float per channel (see TH1 documentation)}
Definition: TH2.h:256
unsigned int UInt_t
Definition: RtypesCore.h:42
The most important graphics class in the ROOT system.
Definition: TPad.h:46
char * Form(const char *fmt,...)
static Int_t GetColor(const char *hexcolor)
Static method returning color number for color specified by hex color string of form: "#rrggbb"...
Definition: TColor.cxx:1023
virtual const char * GetName() const
Returns name of object.
Definition: TNamed.h:51
The ROOT global object gROOT contains a list of all defined classes.
Definition: TClass.h:81
void plot_logo(Float_t v_scale=1.0, Float_t skew=1.0)
Definition: tmvaglob.cxx:263
UInt_t GetWindowWidth() const
Definition: TCanvas.h:184
The Canvas class.
Definition: TCanvas.h:48
static const double x1[5]
virtual void Draw(Option_t *option="")
Draw this pavelabel with its current attributes.
Definition: TPaveLabel.cxx:77
tuple file
Definition: fildir.py:20
double Double_t
Definition: RtypesCore.h:55
Describe directory structure in memory.
Definition: TDirectory.h:44
void dir(char *path=0)
Definition: rootalias.C:30
void draw_synapse(Double_t cx1, Double_t cy1, Double_t cx2, Double_t cy2, Double_t rad1, Double_t rad2, Double_t weightNormed)
Definition: network.cxx:396
Double_t y[n]
Definition: legend1.C:17
The TH1 histogram class.
Definition: TH1.h:80
void draw_layer(TCanvas *c, TH2F *h, Int_t iHist, Int_t nLayers, Double_t maxWeight)
Definition: network.cxx:315
Draw Ellipses.
Definition: TEllipse.h:44
#define name(a, b)
Definition: linkTestLib0.cpp:5
virtual Int_t GetNbinsY() const
Definition: TH1.h:297
virtual TObject * ReadObj()
To read a TObject* from the file.
Definition: TKey.cxx:727
virtual Bool_t cd(const char *path=0)
Change current directory to "this" directory.
Definition: TDirectory.cxx:433
void SetTitleFillColor(Color_t color=1)
Definition: TStyle.h:398
void draw_layer_labels(Int_t nLayers)
Definition: network.cxx:165
#define NULL
Definition: Rtypes.h:82
virtual TText * DrawText(Double_t x, Double_t y, const char *text)
Draw this text with new coordinates.
Definition: TText.cxx:171
virtual void SetTextColor(Color_t tcolor=1)
Definition: TAttText.h:57
Bool_t InheritsFrom(const char *cl) const
Return kTRUE if this class inherits from a class with name "classname".
Definition: TClass.cxx:4498
virtual void SetTextSize(Float_t tsize=1)
Definition: TAttText.h:60
Draw all kinds of Arrows.
Definition: TArrow.h:35
Bool_t MovieMode
Definition: network.cxx:27
const Bool_t kTRUE
Definition: Rtypes.h:91
Color_t GetCanvasColor() const
Definition: TStyle.h:198
virtual void SetBorderSize(Int_t bordersize=4)
Definition: TPave.h:82
void Resize(Ssiz_t n)
Resize the string. Truncate or add blanks as necessary.
Definition: TString.cxx:1045
TImage * findImage(const char *imageName)
Definition: tmvaglob.cxx:245
UInt_t GetListOfTitles(TDirectory *rfdir, TList &titles)
Definition: tmvaglob.cxx:634