Fork me on GitHub

source: svn/trunk/Examples/LHCO_Only.cpp@ 410

Last change on this file since 410 was 273, checked in by Xavier Rouby, 16 years ago

update

File size: 3.3 KB
Line 
1/***********************************************************************
2** **
3** /----------------------------------------------\ **
4** | Delphes, a framework for the fast simulation | **
5** | of a generic collider experiment | **
6** \----------------------------------------------/ **
7** **
8** **
9** This package uses: **
10** ------------------ **
11** FastJet algorithm: Phys. Lett. B641 (2006) [hep-ph/0512210] **
12** Hector: JINST 2:P09005 (2007) [physics.acc-ph:0707.1198v2] **
13** FROG: [hep-ex/0901.2718v1] **
14** **
15** ------------------------------------------------------------------ **
16** **
17** Main authors: **
18** ------------- **
19** **
20** Severine Ovyn Xavier Rouby **
21** severine.ovyn@uclouvain.be xavier.rouby@cern **
22** **
23** Center for Particle Physics and Phenomenology (CP3) **
24** Universite catholique de Louvain (UCL) **
25** Louvain-la-Neuve, Belgium **
26** **
27** Copyright (C) 2008-2009, **
28** All rights reserved. **
29** **
30***********************************************************************/
31
32/// \file LHCO_Only.cpp
33/// \brief standalone executable for running the LHCO-converter
34
35#include "TChain.h"
36#include "TFile.h"
37#include "TApplication.h"
38#include "LHCOConverter.h"
39
40#include "ExRootTreeReader.h"
41#include "ExRootTreeWriter.h"
42#include "ExRootTreeBranch.h"
43#include "BlockClasses.h"
44
45#include <iostream>
46#include <vector>
47#include <fstream>
48#include <iomanip>
49
50
51using namespace std;
52
53
54int main(int argc, char *argv[])
55{
56 int appargc = 2;
57 char *appName= new char[20];
58 char *appOpt= new char[20];
59 sprintf(appName,"LHCO_Only");
60 sprintf(appOpt,"-b");
61 char *appargv[] = {appName,appOpt};
62 TApplication app(appName, &appargc, appargv);
63 delete [] appName;
64 delete [] appOpt;
65
66 if(argc != 2 && argc !=3 ) {
67 cout << " Usage: " << argv[0] << " input_file [runlog_file] " << endl;
68 cout << " input_file - file in Delphes root format," << endl;
69 cout << " [runlog_file] - the corresponding log file (optional) "<<endl;
70 exit(1);
71 }
72
73 string rootfile = argv[1];
74 string logfile;
75 if(argc ==3) logfile=argv[2];
76
77 LHCOConverter converter(rootfile,logfile);
78 converter.CopyRunLogFile();
79 converter.ConvertExRootAnalysisToLHCO();
80
81 cout << "** Exiting..." << endl;
82
83}
84
Note: See TracBrowser for help on using the repository browser.