Changeset 5933


Ignore:
Timestamp:
01/21/05 14:17:41 (20 years ago)
Author:
rico
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars/mtemp/mifae
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mtemp/mifae/Changelog

    r5904 r5933  
    1919                                                 -*-*- END OF LINE -*-*-
    2020
     21 2005/01/21 Javier Rico
     22    * programs/makeHillas.cc, programs/Makefile,
     23      programs/makehillas.datacard
     24     - Add Random Forest computation
     25       
    2126 2005/01/20 Eva Domingo
    2227    * library/MDispParameters.[cc,h]
  • trunk/MagicSoft/Mars/mtemp/mifae/programs/Makefile

    r5879 r5933  
    4747           -I../../../mastro \
    4848           -I../../../mreport \
     49           -I../../../mranforest \
    4950           -I../../../mtemp
    5051
  • trunk/MagicSoft/Mars/mtemp/mifae/programs/makeHillas.cc

    r5827 r5933  
    6363#include "MTopology.h"
    6464#include "MTopologyCalc.h"
     65#include "MRanForest.h"
     66#include "MRanForestCalc.h"
     67#include "MRanForestFill.h"
    6568
    6669#include "TApplication.h"
     
    106109Int_t    wsize   = 6;
    107110Int_t    sext    = 0;
     111TString  rffilename;
    108112
    109113const TString defaultcard="makehillas.datacard";
     
    225229  MPedestalCam pedcamrms;
    226230
     231
     232  /************************************************************************/
     233  /*                 SECOND LOOP TO READ THE RANDOM FOREST FILE(S)         */
     234  /************************************************************************/     
     235  MParList  plistrf;
     236  MTaskList tlistrf;
     237  MRanForest ranforest;
     238
     239  plistrf.AddToList(&tlistrf);
     240  plistrf.AddToList(&ranforest);
     241
     242  MReadTree readrf("Tree",rffilename);
     243  readrf.DisableAutoScheme();
     244 
     245  MRanForestFill rffill;
     246  rffill.SetNumTrees(100);
     247 
     248  tlistrf.AddToList(&readrf);
     249  tlistrf.AddToList(&rffill);
     250
     251  MEvtLoop evtlooprf;
     252  evtlooprf.SetParList(&plistrf);
     253  if (!evtlooprf.Eventloop())
     254    return;
     255 
     256  tlistrf.PrintStatistics();
     257
     258
    227259  /*****************************/
    228   /* SECOND LOOP: CALIBRATION  */
     260  /* THIRD LOOP: CALIBRATION  */
    229261  /*****************************/       
    230262
     
    242274  chargecam.Print();
    243275
    244 
    245276  /************************************************************************/
    246   /*                 THIRD (SMALL) LOOP TO GET INITIAl PEDESTALS          */
     277  /*                 FOURTH (SMALL) LOOP TO GET INITIAl PEDESTALS          */
    247278  /************************************************************************/     
    248279  MParList  plist3;
     
    322353    {
    323354      /************************************************************************/
    324       /*                 FOURTH (SMALL) LOOP TO GET INITIAl PEDESTALS RMS     */
     355      /*                 SIXTH (SMALL) LOOP TO GET INITIAl PEDESTALS RMS     */
    325356      /************************************************************************/     
    326357      MParList  plist4;
     
    405436  plist5.AddToList(&reportdrive);
    406437  plist5.AddToList(&topology);
    407  
     438  plist5.AddToList(&ranforest);
     439
    408440  // cuts
    409441  MF cut(filter);
     
    435467  MIslandsCalc       island3;
    436468  island3.SetOutputName("MIslands3"); 
    437  
     469
     470  MRanForestCalc hadrcalc;
    438471 
    439472  MHillasCalc       hcalc;
     
    503536  if(topflag>0)
    504537    tlist5.AddToList(&topcalc);
     538  if(rffilename.Length())
     539    tlist5.AddToList(&hadrcalc);
    505540  tlist5.AddToList(&write);
    506541  if(display)
     
    639674            }
    640675          }
     676        }
     677
     678      // random forest file name
     679      if(strcmp(word.Data(),"RANFOREST")==0)
     680        {
     681          if(rffilename.Length())
     682            cout << "readDataCards Warning: overriding random forest file name" << endl;
     683          ifun >> rffilename;
    641684        }
    642685     
     
    703746  cout << "Cleaning level: ("<<lcore<<","<<ltail<<") - " << lrings << "ring" << endl;
    704747  cout << "Cleaning method: "<< cleanflag << endl;
     748  if(rffilename.Length())
     749    cout << "Random Forest will be read from " << rffilename << endl;
    705750  if (islflag == 1 || islflag == 2)
    706751    cout << "Island calcultation..." << "using algorithm #" << kalgorithm <<endl;
  • trunk/MagicSoft/Mars/mtemp/mifae/programs/makehillas.datacard

    r5827 r5933  
    6363CLEANLEVEL 4.0 3.5 1 1
    6464
     65// Add the following word if you want to include Hadronness calculation,
     66// followed by the name of the Random Forest file
     67RANFOREST RFstd.root
     68
    6569//Island calculations
    6670// 0  same as 1                1:normal algorithm
Note: See TracChangeset for help on using the changeset viewer.