16 |
full1 = 0; |
full1 = 0; |
17 |
geth = 0; |
geth = 0; |
18 |
get2 = 1; |
get2 = 1; |
19 |
|
gete = 1; |
20 |
standalone = false; |
standalone = false; |
21 |
frame2 = "root"; |
frame2 = "root"; |
22 |
frame1 = "root"; |
frame1 = "root"; |
23 |
frameh = "root"; |
frameh = "root"; |
24 |
|
framee = "root"; |
25 |
outdir = gSystem->WorkingDirectory(); |
outdir = gSystem->WorkingDirectory(); |
26 |
pfolder = "/TrackerFolder"; |
pfolder = "/TrackerFolder"; |
27 |
if (!frame2.CompareTo("root", TString::kIgnoreCase)) ifroot2 = true; |
if (!frame2.CompareTo("root", TString::kIgnoreCase)) ifroot2 = true; |
38 |
|
|
39 |
ostatus = 0; |
ostatus = 0; |
40 |
|
|
41 |
npar=0; |
npar = 0; |
42 |
|
|
43 |
|
nskip = 0; |
44 |
|
|
45 |
TrkParams::SetTrackingMode(); |
// TrkParams::SetTrackingMode(); |
46 |
TrkParams::SetPrecisionFactor(); |
// TrkParams::SetPrecisionFactor(); |
47 |
TrkParams::SetStepMin(); |
// TrkParams::SetStepMin(); |
48 |
|
TrkParams::SetMiniDefault(); |
49 |
TrkParams::SetPFA(); |
TrkParams::SetPFA(); |
50 |
}; |
}; |
51 |
|
|
64 |
full1 = 0; |
full1 = 0; |
65 |
get2 = 1; |
get2 = 1; |
66 |
geth = 0; |
geth = 0; |
67 |
|
gete = 1; |
68 |
standalone = false; |
standalone = false; |
69 |
frame2 = "root"; |
frame2 = "root"; |
70 |
frame1 = "root"; |
frame1 = "root"; |
71 |
frameh = "root"; |
frameh = "root"; |
72 |
|
framee = "root"; |
73 |
pfolder = "/TrackerFolder"; |
pfolder = "/TrackerFolder"; |
74 |
file1 = ""; |
file1 = ""; |
75 |
if(f2->IsOpen()){ |
if(f2->IsOpen()){ |
96 |
|
|
97 |
npar=0; |
npar=0; |
98 |
|
|
99 |
TrkParams::SetTrackingMode(); |
nskip = 0; |
100 |
TrkParams::SetPrecisionFactor(); |
|
101 |
TrkParams::SetStepMin(); |
// TrkParams::SetTrackingMode(); |
102 |
|
// TrkParams::SetPrecisionFactor(); |
103 |
|
// TrkParams::SetStepMin(); |
104 |
|
TrkParams::SetMiniDefault(); |
105 |
TrkParams::SetPFA(); |
TrkParams::SetPFA(); |
106 |
|
|
107 |
}; |
}; |
112 |
|
|
113 |
for (int i=0; i< ncustom; i++){ |
for (int i=0; i< ncustom; i++){ |
114 |
|
|
115 |
|
cout << "Handling Parameter " << i+1 << " of " << ncustom << ": " << vcustom[i] << endl; |
116 |
|
|
117 |
|
// -----------------------------------------------------// |
118 |
|
if (!strcmp(vcustom[i], "--simu")){ |
119 |
|
cout << "Setting DarthVader to use Simulated Data\n"; |
120 |
|
TrkParams::SetSimuFlag(kTRUE); |
121 |
|
continue; |
122 |
|
} |
123 |
// -----------------------------------------------------// |
// -----------------------------------------------------// |
124 |
if (!strcmp(vcustom[i], "-processFolder")){ |
if (!strcmp(vcustom[i], "-processFolder")){ |
125 |
if (++i >= ncustom) throw -3; |
if (++i >= ncustom) throw -3; |
149 |
continue; |
continue; |
150 |
} |
} |
151 |
// -----------------------------------------------------// |
// -----------------------------------------------------// |
152 |
|
if (!strcmp(vcustom[i], "--dontgete") ||!strcmp(vcustom[i], "--dontget-exttrack") ){ |
153 |
|
gete = 0; |
154 |
|
continue; |
155 |
|
} |
156 |
|
// -----------------------------------------------------// |
157 |
if (!strcmp(vcustom[i], "--standalone") || !strcmp(vcustom[i], "-s")){ |
if (!strcmp(vcustom[i], "--standalone") || !strcmp(vcustom[i], "-s")){ |
158 |
standalone = true; |
standalone = true; |
159 |
continue; |
continue; |
180 |
continue; |
continue; |
181 |
} |
} |
182 |
// -----------------------------------------------------// |
// -----------------------------------------------------// |
183 |
|
if (!strcmp(vcustom[i], "-framee")){ |
184 |
|
if (++i >= ncustom)throw -3; |
185 |
|
gete = 1; |
186 |
|
framee = vcustom[i]; |
187 |
|
continue; |
188 |
|
} |
189 |
|
// -----------------------------------------------------// |
190 |
if (!strcmp(vcustom[i], "-pfa")){ |
if (!strcmp(vcustom[i], "-pfa")){ |
191 |
if (++i >= ncustom)throw -3; |
if (++i >= ncustom)throw -3; |
192 |
TrkParams::SetPFA(atoi(vcustom[i])); |
TrkParams::SetPFA(atoi(vcustom[i])); |
193 |
continue; |
continue; |
194 |
} |
} |
195 |
// -----------------------------------------------------// |
// -----------------------------------------------------// |
196 |
|
if (!strcmp(vcustom[i], "-skip")){ |
197 |
|
if (++i >= ncustom)throw -3; |
198 |
|
nskip = atoi(vcustom[i]); |
199 |
|
continue; |
200 |
|
} |
201 |
|
// -----------------------------------------------------// |
202 |
if ( atoi(vcustom[i]) < 0){ |
if ( atoi(vcustom[i]) < 0){ |
203 |
if (++i >= ncustom)throw -3; |
if (++i >= ncustom)throw -3; |
204 |
partype[npar]=-1*atoi(vcustom[i-1]); |
partype[npar]=-1*atoi(vcustom[i-1]); |
240 |
else if (!frameh.CompareTo("hbook", TString::kIgnoreCase)) ifrooth =false; |
else if (!frameh.CompareTo("hbook", TString::kIgnoreCase)) ifrooth =false; |
241 |
else throw -201; |
else throw -201; |
242 |
|
|
243 |
|
if (!framee.CompareTo("root", TString::kIgnoreCase)) ifroote = true; |
244 |
|
else if (!framee.CompareTo("hbook", TString::kIgnoreCase)) ifroote =false; |
245 |
|
else throw -201; |
246 |
|
|
247 |
if(get1 && !get2)full1=true; |
if(get1 && !get2)full1=true; |
248 |
|
|
249 |
ostatus = 0; |
ostatus = 0; |
269 |
// |
// |
270 |
if(get2) analysisflight_(); |
if(get2) analysisflight_(); |
271 |
// |
// |
272 |
|
|
273 |
ostatus = F77err; |
ostatus = F77err; |
274 |
|
|
275 |
}; |
}; |
279 |
cout << " |-------------------------------------| "<<endl; |
cout << " |-------------------------------------| "<<endl; |
280 |
cout << " tracker-processing input-parameters "<< endl; |
cout << " tracker-processing input-parameters "<< endl; |
281 |
cout << " |-------------------------------------| "<<endl; |
cout << " |-------------------------------------| "<<endl; |
282 |
cout << " idRun " << idrun << endl; |
cout << " idRun " << idrun << endl; |
283 |
cout << " get level1 " << get1 << endl; |
cout << " (skip " << nskip <<" events)"<< endl; |
284 |
cout << " full level1 " << full1 << endl; |
cout << " get level1 " << get1 << endl; |
285 |
cout << " get level2 " << get2 << endl; |
cout << " full level1 " << full1 << endl; |
286 |
cout << " get hough " << geth << endl; |
cout << " get level2 " << get2 << endl; |
287 |
// cout << " frame1 " << frame1 << endl; |
cout << " get hough " << geth << endl; |
288 |
// cout << " frame2 " << frame2 << endl; |
cout << " get ext.tracking " << gete << endl; |
289 |
// cout << " frameh " << frame2 << endl; |
// cout << " frame1 " << frame1 << endl; |
290 |
// cout << " file1 " << file1 << endl; |
// cout << " frame2 " << frame2 << endl; |
291 |
cout << " output file " << file2 << endl; |
// cout << " frameh " << frame2 << endl; |
292 |
// cout << " outdir " << outdir << endl; |
// cout << " file1 " << file1 << endl; |
293 |
// cout << " process folder " << pfolder << endl; |
cout << " output file " << file2 << endl; |
294 |
// cout << " standalone mode " << standalone << endl; |
// cout << " outdir " << outdir << endl; |
295 |
|
// cout << " process folder " << pfolder << endl; |
296 |
|
// cout << " standalone mode " << standalone << endl; |
297 |
for(int i=0; i<npar; i++) |
for(int i=0; i<npar; i++) |
298 |
cout << " force loading parameters of type "<<partype[i]<<" from <--- "<<parpath[i]<<endl; |
cout << " force loading parameters of type "<<partype[i]<<" from <--- "<<parpath[i]<<endl; |
299 |
cout<<endl; |
cout<<endl; |
320 |
printf( "\n --get1, --get-level1 : get LEVEL1 output (store only cluster associated to tracks) [default (no LEVEL1 output) ] "); |
printf( "\n --get1, --get-level1 : get LEVEL1 output (store only cluster associated to tracks) [default (no LEVEL1 output) ] "); |
321 |
printf( "\n --get1-full, --get-level1-full : get LEVEL1 output (store all clusters) [default (no LEVEL1 output) ] "); |
printf( "\n --get1-full, --get-level1-full : get LEVEL1 output (store all clusters) [default (no LEVEL1 output) ] "); |
322 |
printf( "\n --dontget2, --dontget-level2 : do not get LEVEL2 output [default (get LEVEL2 output)]"); |
printf( "\n --dontget2, --dontget-level2 : do not get LEVEL2 output [default (get LEVEL2 output)]"); |
323 |
|
printf( "\n --dontgete, --dontget-exttrack : do not get ext.tracking output [default (get LEVEL2 output)]"); |
324 |
printf( "\n --geth,, --get-hough : get Hough-transform output [default (no Hough-t. output) ] "); |
printf( "\n --geth,, --get-hough : get Hough-transform output [default (no Hough-t. output) ] "); |
325 |
printf( "\n -pfa PFAID : type of output for LEVEL2, root/hbook [default 14 (COG4) ] "); |
printf( "\n -pfa PFAID : type of output for LEVEL2, root/hbook [default 14 (COG4) ] "); |
326 |
printf( "\n -N PATH : load parameter of type N=1,2... from PATH [default (from DB) ] "); |
printf( "\n -N PATH : load parameter of type N=1,2... from PATH [default (from DB) ] "); |
327 |
printf( "\n --verbose, -v : verbose mode "); |
printf( "\n --verbose, -v : verbose mode "); |
328 |
printf( "\n --debug, -d : debug mode "); |
printf( "\n --debug, -d : debug mode "); |
329 |
printf( "\n --warning, -w : warning mode "); |
printf( "\n --warning, -w : warning mode "); |
330 |
|
printf( "\n -skip NEV : skip first NEV events from each run "); |
331 |
// printf( "\n --standalone, -s : standalone mode (without RunInfo) ... but it might not work \n"); |
// printf( "\n --standalone, -s : standalone mode (without RunInfo) ... but it might not work \n"); |
332 |
// printf( "\n -host HOST : Name for the host [default mysql://localhost/pamelaprod ]"); |
// printf( "\n -host HOST : Name for the host [default mysql://localhost/pamelaprod ]"); |
333 |
// printf( "\n -user USER : Username for the DB [default anonymous] "); |
// printf( "\n -user USER : Username for the DB [default anonymous] "); |