Logo Coherent WaveBurst  
Reference Guide
Logo
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
LoopChirpMass.C
Go to the documentation of this file.
1 #define IDIR "/home/shubhanshu.tiwari/EBBH/catalogue/O1/O1_C01_SIM_eBBH_10_10_snr_20_e_0_500/output/"
2 #define OFILE "ebbh_10_10_snr_20_e_0_500.txt"
3 
4 //#define IDIR "/home/shubhanshu.tiwari/EBBH/catalogue/O1/O1_C01_SIM_eBBH_10_10_snr_20_e_6_500/output/"
5 //#define OFILE "ebbh_10_10_snr_20_e_6_500.txt"
6 
7 //#define IDIR "/home/shubhanshu.tiwari/EBBH/catalogue/O1/O1_C01_SIM_eBBH_10_10_snr_20_e_8_500/output/"
8 //#define OFILE "ebbh_10_10_snr_20_e_8_500.txt"
9 
10 {
11 /*
12  TTree itree("ebbh","ebbh")
13  itree.ReadFile("ebbh_10_10_snr_20_e_0_500.txt","m1/F:m2:s1/F:s2/F:e/F:rp/F:dist/F:redshift/F:mch/F:ech/F:ei/F")
14  itree.Draw("mch")
15  itree.Draw("ei")
16  itree.Draw("ech")
17  itree.Draw("e")
18 */
19 /*
20  TString ifile = TString::Format("%s/*_1_job4000.root",IDIR);
21  ChirpMass(ifile);
22 */
23 
24  gROOT->LoadMacro("/home/vedovato/WP/eBBH/MACROS/ChirpMass.C");
25 
26  EBBH* ebbh = new EBBH;
27 
28  TString TAG = "";
29 
30  vector<TString> fList = CWB::Toolbox::getFileListFromDir(IDIR, ".root", "wave_", TAG, true);
31 
32  cout << "Number of files : " << fList.size() << endl;
33 
34  ofstream out;
35  out.open(OFILE);
36  for(int n=0; n<fList.size(); n++) {
37  cout << fList[n] << endl;
38  double status = ChirpMass(fList[n],0,0,0,ebbh);
39 
40  cout << n << " -> Eccentricity Index = " << ebbh->ei << " status : " << status << endl;
41 
42  out << ebbh->mass[0] << " " << ebbh->mass[0] << " "
43  << ebbh->spin[2] << " " << ebbh->spin[5] << " "
44  << ebbh->e0 << " " << ebbh->rp0 << " " << ebbh->dist << " " << ebbh->redshift << " "
45  << ebbh->ch_mass[0] << " " << ebbh->ch_energy[0] << " " << ebbh->ei << endl;
46  }
47  out.close();
48 
49  exit(0);
50 }
int ChirpMass(TString ifroot, int gtype=0, int entry=0, int ifo=0, EBBH *xebbh=NULL)
Definition: ChirpMass.C:130
static vector< TString > getFileListFromDir(TString dir_name, TString endString="", TString beginString="", TString containString="", bool fast=false)
Definition: Toolbox.cc:4333
int n
Definition: cwb_net.C:10
TString("c")
TString TAG
Definition: LoopChirpMass.C:28
#define OFILE
Definition: LoopChirpMass.C:2
ofstream out
Definition: cwb_merge.C:196
EBBH * ebbh
Definition: LoopChirpMass.C:26
vector< TString > fList
Definition: LoopChirpMass.C:30
#define IDIR
Definition: LoopChirpMass.C:1
exit(0)