Changeset 6066 for trunk


Ignore:
Timestamp:
01/28/05 09:12:44 (20 years ago)
Author:
moralejo
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r6059 r6066  
    2020
    2121                                                 -*-*- END OF LINE -*-*-
     22 2005/01/28 Abelardo Moralejo
     23
     24   * mtemp/mpadova/macros/trainsubsample.C
     25     - added # of events to be written in the output (instead of
     26       fraction of total).
     27
    2228 2005/01/27 Daniel Mazin and Markus Gaug
    2329
  • trunk/MagicSoft/Mars/mtemp/mpadova/macros/trainsubsample.C

    r5831 r6066  
    4242  plist.AddToList(&tlist);
    4343
    44   MReadMarsFile  read("Events", "star_20040915_CrabNebulaW1.root");
     44  MReadMarsFile  read("Events", "star_20040915_CrabNebulaW2.root");
    4545
    4646  MFEventSelector evsel;
    47   evsel.SetSelectionRatio(0.05); // Fraction of events in output
     47
     48  Float_t nevents = 50000;   // Number of events to select.
     49  Float_t ratio = nevents / (Float_t) read.GetEntries();
     50
     51  evsel.SetSelectionRatio(ratio); // Fraction of events in output
    4852
    4953  read.DisableAutoScheme();
     
    5458  plist.AddToList(mcevt);
    5559
    56   MWriteRootFile write("star_train_20040915_CrabNebulaW1.root", "recreate");
     60  MWriteRootFile write("star_train_20040915_CrabNebulaW2.root", "recreate");
    5761
    5862  write.AddContainer("MMcEvt",         "Events", kFALSE);
Note: See TracChangeset for help on using the changeset viewer.