48 if(gSystem->Getenv(
"CWB_DOC_URL")!=NULL) {
49 cwb_doc_url=
TString(gSystem->Getenv(
"CWB_DOC_URL"));
61 TString NetCC,Rho,RhOut,RhAcor,svED,sPEN,sHRSS,sfLow,sfHigh,sfResample,spp_rho_min,spp_rho_max;
78 TTree* wave_tree = (TTree*)psp->Get(
"waveburst");
85 cout << fileout << endl;
87 if (!out.good()) {cout <<
"Error Opening File : " << fileout << endl;
exit(1);}
99 for(
int i=0;
i<epsList.size();
i++) {
101 ofile.ReplaceAll(
".eps",
".gif");
103 sprintf(cmd,
"convert %s %s",epsList[
i].Data(),ofile.Data());
106 sprintf(cmd,
"rm %s",epsList[
i].Data());
113 sprintf(fileliv,
"%s/live.txt",PP_DATA_PATH.Data());
114 cout << fileliv << endl;
116 double OLIVETIME =
GetLiveTime(fileliv,0,0,countlag);
117 double LIVETIME =
GetLiveTime(fileliv,-1,-1,countlag);
121 cout << OLIVETIME <<
" " << LIVETIME << endl;
131 bkgin.getline(istring,256);
132 if (!bkgin.good())
break;
135 ostringa.ReplaceAll(
"<!--VETO",
"");
136 ostringa.ReplaceAll(
"VETO-->",
"");
138 ostringa.ReplaceAll(
"<!--NOVETO",
"");
139 ostringa.ReplaceAll(
"VETONO-->",
"");
142 ostringa.ReplaceAll(
"<!--RHO_PF",
"");
143 ostringa.ReplaceAll(
"RHO_PF-->",
"");
145 ostringa.ReplaceAll(
"<!--RHO_SUBNET",
"");
146 ostringa.ReplaceAll(
"RHO_SUBNET-->",
"");
148 if(pp_rho_vs_rate_no_multiplicity) {
149 ostringa.ReplaceAll(
"<!--MULTI",
"");
150 ostringa.ReplaceAll(
"MULTI-->",
"");
152 ostringa.ReplaceAll(
"FLOW",sfLow);
153 ostringa.ReplaceAll(
"FHIGH",sfHigh);
154 ostringa.ReplaceAll(
"PP_RHO_MIN",spp_rho_min);
155 ostringa.ReplaceAll(
"PP_RHO_MAX",spp_rho_max);
156 ostringa.ReplaceAll(
"PP_DATA_DIR",PP_DATA_DIR);
157 ostringa.ReplaceAll(
"NETCC",NetCC);
158 ostringa.ReplaceAll(
"RHO",Rho);
159 ostringa.ReplaceAll(
"RH_OUT",RhOut);
160 ostringa.ReplaceAll(
"RH_ACOR",RhAcor);
161 ostringa.ReplaceAll(
"svED",svED);
163 ostringa.ReplaceAll(
"RATEBACKGROUND",Rate);
164 ostringa.ReplaceAll(
"SUBTITLE",
subtitle);
165 ostringa.ReplaceAll(
"TITLE",
title);
167 sprintf(ltime,
"zero lag : <font color=\"red\"> %.2f sec = %.2f days</font>",
168 OLIVETIME,OLIVETIME/86400.);
169 ostringa.ReplaceAll(
"LIVETIME",ltime);
170 sprintf(ltime,
"non-zero lags : <font color=\"red\"> %i lags - %.2f sec = %.2f days = %.1f years </fonts>",
171 countlag,LIVETIME,LIVETIME/(
float)86400.,LIVETIME/86400./365.);
172 ostringa.ReplaceAll(
"LIVETIM2",ltime);
174 if(cwb_doc_url!=
"") {
175 ostringa.ReplaceAll(
"<!--CWB_DOC_URL",
"");
176 ostringa.ReplaceAll(
"CWB_DOC_URL-->",
"");
177 ostringa.ReplaceAll(
"XCWB_DOC_URL",cwb_doc_url.Data());
180 ostringa.ReplaceAll(
"</html>",
"");
181 out << ostringa.Data() << endl;
192 sprintf(file_ev,
"%s/events.txt",PP_DATA_PATH.Data());
193 ifstream for_ev(file_ev);
194 char file_header[1024];
195 sprintf(file_header,
"%s/events_header.txt",PP_DATA_PATH.Data());
196 ofstream for_header(file_header);
197 char file_notsorted[1024];
198 sprintf(file_notsorted,
"%s/events_notsorted.txt",PP_DATA_PATH.Data());
199 ofstream for_notsorted(file_notsorted);
202 for_ev.getline(in_ev,100000);
203 if (!for_ev.good())
break;
205 if (sin_ev.Contains(
"#")) for_header << sin_ev.Data() << endl;
206 else for_notsorted << sin_ev.Data() << endl;
209 for_notsorted.close();
210 char file_sorted[1024];
211 sprintf(file_sorted,
"%s/events_sorted.txt",PP_DATA_PATH.Data());
212 sprintf(exec,
"sort -g -r --key=3 %s > %s",file_notsorted, file_sorted);
214 sprintf(exec,
"cat %s %s > %s/EVENTS.txt",file_header, file_sorted, PP_DATA_PATH.Data());
217 sprintf(file_notsorted,
"%s/events_notsorted.txt",PP_DATA_PATH.Data());
218 ifstream
f_ev(file_sorted);
221 float icc,
irho,
iacor,
ilag,
islag,
ilik,
ipen,
icHH,
ivHH,
ivED,
icc2,
icc3;
232 out <<
"<table border=0 cellpadding=2 class=\"datagrid\">" << endl;
233 out <<
"<tr align=\"center\">"<< endl;
234 out <<
"<td>ID</td>"<< endl;
235 if(bhveto) out <<
"<td>KW</td>"<< endl;
236 if(bcat3) out <<
"<td>cat3 </td>"<< endl;
237 out <<
"<td>rho["<<
pp_irho<<
"]</td>"<< endl;
238 out <<
"<td>cc["<<
pp_inetcc<<
"]</td>"<< endl;
239 if(
TString(analysis)==
"2G") out <<
"<td>subnet</td>"<< endl;
241 out <<
"<td>lag</td>"<< endl;
242 out <<
"<td>slag</td>"<< endl;
243 out <<
"<td>SNRnet</td>"<< endl;
244 if(
TString(analysis)==
"1G") out <<
"<td>pf</td>"<< endl;
245 if(
TString(analysis)==
"1G") out <<
"<td>vED</td>"<< endl;
246 out <<
"<td>freq</td>"<< endl;
247 out <<
"<td>bw</td>"<< endl;
248 out <<
"<td>dur</td>"<< endl;
249 out <<
"<td>size</td>"<< endl;
250 if(
optim==
true) out <<
"<td>res</td>"<< endl;
251 out <<
"<td>run</td>"<< endl;
252 for (
int nn=0;nn<
nIFO;nn++) out <<
"<td>GPS " << _ifo[nn] <<
"</td>"<< endl;
253 for (
int nn=0;nn<
nIFO;nn++) out <<
"<td>SNR " << _ifo[nn] <<
"</td>"<< endl;
260 out <<
"</tr>"<< endl;
265 f_ev>>pm>>c3>>irho>>icc>>icc2>>icc3>>iacor>>ilag>>islag>>ilik>>ipen>>icHH>>ifreq>>iband>>idur>>isize>>irate>>irun>>time0>>time1>>time2>>time3>>SNR0>>SNR1>>SNR2>>SNR3>>hrss0>>hrss1>>hrss2>>hrss3>>phi>>theta>>
psi;
267 f_ev>>pm>>c3>>irho>>icc>>icc2>>icc3>>iacor>>ilag>>islag>>ilik>>ipen>>icHH>>ifreq>>iband>>idur>>isize>>irate>>irun>>time0>>time1>>time2>>SNR0>>SNR1>>SNR2>>hrss0>>hrss1>>hrss2>>phi>>theta>>
psi;
269 f_ev>>pm>>c3>>irho>>icc>>icc2>>icc3>>iacor>>ilag>>islag>>ilik>>ipen>>icHH>>ifreq>>iband>>idur>>isize>>irate>>irun>>time0>>time1>>SNR0>>SNR1>>hrss0>>hrss1>>phi>>theta>>
psi;
271 if (!
f_ev.good())
break;
274 if (ppm.Contains(
"+")) {
276 cout << ecount <<
" ";cout.flush();
277 out <<
"<tr align=\"center\">"<< endl;
283 start[0]=
GetStart(wave_tree, 0, irun, irho, time0, time1, analysis,
pp_irho);
286 for (
int nn=0; nn<
nIFO; nn++)
sprintf(namedir,
"%s%s",namedir,_ifo[nn]);
287 for (
int nn=0; nn<
nIFO; nn++) {
288 start[nn]=
GetStart(wave_tree, nn, irun, irho, time0, time1, analysis,
pp_irho);
289 sprintf(namedir,
"%s_%.3f",namedir,start[nn]);
292 sprintf(os,
"<td><a href=\"ced/ced_%s/%s\" target=\"_blank\">%i</a></td>",s_ced.Data(),namedir,
ecount);
295 sprintf(os,
"<td>%s</td>",ppm.Remove(0,1).Data());
299 sprintf(os,
"<td>%s</td>",cc3.Remove(0,1).Data());
302 sprintf(os,
"<td>%.2f</td>",irho);
304 sprintf(os,
"<td>%.2f</td>",icc);
307 sprintf(os,
"<td>%.2f</td>",icc2);
314 sprintf(os,
"<td>%i</td>",(
int)ilag);
316 sprintf(os,
"<td>%i</td>",(
int)islag);
318 sprintf(os,
"<td>%3.1f</td>",sqrt(ilik));
320 sprintf(os,
"<td>%.3f</td>",ipen);
321 if(
TString(analysis)==
"1G") out << os << endl;
322 sprintf(os,
"<td>%.3f</td>",icHH);
323 if(
TString(analysis)==
"1G") out << os << endl;
324 sprintf(os,
"<td><font color=\"black\">%i</font></td>",ifreq);
326 sprintf(os,
"<td>%i</td>",iband);
328 sprintf(os,
"<td>%.3f</td>",idur);
330 sprintf(os,
"<td>%i</td>",isize);
332 sprintf(os,
"<td>%i</td>",irate);
333 if(
optim==
true) out << os << endl;
334 sprintf(os,
"<td>%i</td>",irun);
336 sprintf(os,
"<td>%.2f</td>",time0);
339 sprintf(os,
"<td>%.2f</td>",time1);
343 sprintf(os,
"<td>%.2f</td>",time2);
347 sprintf(os,
"<td>%.2f</td>",time3);
350 sprintf(os,
"<td>%3.1f</td>",sqrt(SNR0));
353 sprintf(os,
"<td>%3.1f</td>",sqrt(SNR1));
357 sprintf(os,
"<td>%3.1f</td>",sqrt(SNR2));
361 sprintf(os,
"<td>%3.1f</td>",sqrt(SNR3));
384 out <<
"</tr>" << endl;
390 out <<
"</table>" << endl;
391 out <<
"<p>" << endl;
394 cout << exec << endl;
397 sprintf(file_notsorted,
"%s/events_notsorted.txt",PP_DATA_PATH.Data());
398 sprintf(exec,
"rm %s",file_notsorted);
399 cout << exec << endl;
401 sprintf(exec,
"rm %s",file_header);
402 cout << exec << endl;
405 out <<
"</table>" << endl;
406 out <<
"<p>" << endl;
void Export(TString fname="")
sprintf(netdir,"%s/%s", pp_dir, pp_data_dir)
char html_body_prod_template[1024]
char channelNamesRaw[NIFO_MAX][50]
vector< TString > epsList
cout<< "baudline_FFL : "<< baudline_FFL<< endl;ofstream out;out.open(baudline_FFL, ios::out);if(!out.good()) {cout<< "Error Opening File : "<< baudline_FFL<< endl;exit(1);} ifstream in;in.open(frFiles[ifoID], ios::in);if(!in.good()) {cout<< "Error Opening File : "<< frFiles[ifoID]<< endl;exit(1);} TString pfile_path="";char istring[1024];while(1) { in > istring
void Import(TString umacro="")
ifstream f_ev(file_sorted)
strcpy(RunLabel, RUN_LABEL)
detectorParams detParms[4]
void SetSingleDetectorMode()