ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitHzz4l/ElectronStudies/src/runZeeTreeWriter.cc
(Generate patch)

Comparing UserCode/MitHzz4l/ElectronStudies/src/runZeeTreeWriter.cc (file contents):
Revision 1.2 by anlevin, Wed Jul 18 09:31:12 2012 UTC vs.
Revision 1.3 by anlevin, Thu Jul 26 22:41:07 2012 UTC

# Line 1 | Line 1
1 < //./bin/runZeeTreeWriter.exe --catalogDir "/home/mitprod/catalog" --book "cern/filefi/028" --dataset "s12-zllm50-2-v9" --fileset "0000" --output_filename "delete.root"  --is_data 0 --n_events_to_process 1000
1 > //./bin/runZeeTreeWriter.exe --catalogDir "/home/cmsprod/catalog" --book "t2mit/filefi/028" --dataset "s12-zllm50-2-v9" --fileset "0000" --output_filename "delete.root"  --is_data 0 --n_events_to_process 1000 --rho rho_kt_6_pf_jets
2  
3   #include "ZeeTreeWriterMod.h"
4   #include "ZeeTreeWriterArgs.h"
# Line 9 | Line 9 | int main(int argc, char** argv)
9    ZeeTreeWriterFlags ctrl;
10  
11     parse_zee_tree_writer_args( argc, argv, ctrl );
12 <   if( ctrl.catalogDir.empty() || ctrl.book.empty() || ctrl.dataset.empty()|| ctrl.fileset.empty()|| ctrl.output_filename.empty()|| !(ctrl.is_data == 0 || ctrl.is_data == 1) || ctrl.n_events_to_process == -2)
12 >   if( ctrl.catalogDir.empty() || ctrl.book.empty() || ctrl.dataset.empty()|| ctrl.fileset.empty()|| ctrl.output_filename.empty()|| !(ctrl.is_data == 0 || ctrl.is_data == 1) || ctrl.n_events_to_process == -2 || ctrl.rho.empty())
13      {
14        cerr << "usage: runZeeTreeWriter.exe <flags> " << endl;
15        ctrl.dump();
# Line 17 | Line 17 | int main(int argc, char** argv)
17        return 1;
18      }
19    ctrl.dump();
20 +  assert(ctrl.rho == "rho" || ctrl.rho == "rho_kt_6_pf_jets");
21 +
22    
23    mithep::ZeeTreeWriterMod *zeetwMod = new mithep::ZeeTreeWriterMod;
24    mithep::Analysis *ana = new mithep::Analysis;
# Line 27 | Line 29 | int main(int argc, char** argv)
29  
30    ana->AddSuperModule(zeetwMod);
31      
32 +  if(ctrl.rho == "rho_kt_6_pf_jets")
33 +    zeetwMod->rho_version = mithep::ZeeTreeWriterMod::e_rho_kt_6_pf_jets;
34 +  else if (ctrl.rho == "rho")
35 +    zeetwMod->rho_version = mithep::ZeeTreeWriterMod::e_rho;
36 +  else
37 +    assert(0);
38 +
39 +
40    mithep::Catalog *c = new mithep::Catalog(TString(ctrl.catalogDir));
41    mithep::Dataset *d = c->FindDataset(TString(ctrl.book),TString(ctrl.dataset),TString(ctrl.fileset));
42    ana->AddDataset(d);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines