| 2 |
* FTrkScanQlook_EXPERT.cxx |
* FTrkScanQlook_EXPERT.cxx |
| 3 |
* |
* |
| 4 |
* autor: D.Fedele |
* autor: D.Fedele |
| 5 |
* version v2r01 |
* version v2r07 |
| 6 |
* Parameters: |
* Parameters: |
| 7 |
* file - the path to the root file to analyze |
* file - the path to the root file to analyze |
| 8 |
* outdir - total path of output file |
* outdir - total path of output file |
| 202 |
printf(" Number of Header Entries: %d\n",neventH); |
printf(" Number of Header Entries: %d\n",neventH); |
| 203 |
printf(" Number of Calibration: %d\n",cevents); |
printf(" Number of Calibration: %d\n",cevents); |
| 204 |
|
|
| 205 |
Long64_t obt=0; |
ULong_t obt=0,hobt[neventH]; |
| 206 |
Int_t eve,cin=0,cins=0; |
Int_t eve,cin=0,cins=0,br=0; |
| 207 |
TString cal=""; |
TString cal=""; |
| 208 |
|
|
| 209 |
eve=3; |
eve=3; |
| 210 |
for(Int_t i=0;i<neventH;i++){ |
for(Int_t i=0;i<neventH;i++){ |
| 211 |
otr->GetEntry(i); |
otr->GetEntry(i); |
| 212 |
pH = eH->GetPscuHeader(); |
pH = eH->GetPscuHeader(); |
| 213 |
if(reh->TRK_CALIB_USED!=104){ |
hobt[i]= pH->GetOrbitalTime(); |
| 214 |
|
if(reh->TRK_CALIB_USED!=104 && br==0){ |
| 215 |
obt = pH->GetOrbitalTime(); |
obt = pH->GetOrbitalTime(); |
| 216 |
cal="Event with online calibration"; |
cal="Event with online calibration"; |
| 217 |
break; |
br=1; |
| 218 |
} |
} |
| 219 |
if(i==neventH-1){ |
if(i==neventH-1 && br==0){ |
| 220 |
cal="***** ONLINE CALIBRATION NOT FOUND IN THIS FILE *****"; |
cal="***** ONLINE CALIBRATION NOT FOUND IN THIS FILE *****"; |
| 221 |
eve=2; |
eve=2; |
| 222 |
} |
} |
| 283 |
eve=i+3; |
eve=i+3; |
| 284 |
cin=100; |
cin=100; |
| 285 |
} |
} |
| 286 |
else if(event>=0 && ph->GetOrbitalTime()>obt && obt>0){ |
else if(event>=0 && (ULong_t)ph->GetOrbitalTime()>obt && obt>0){ |
| 287 |
eve=i+3; |
eve=i+3; |
| 288 |
obt=-1; |
obt=0; |
| 289 |
} |
} |
| 290 |
} |
} |
| 291 |
if(i==0) cins=cod->Get(pctp->CalibTrk1); |
if(i==0) cins=cod->Get(pctp->CalibTrk1); |
| 302 |
csum[cins-1]->SetFillColor(10); |
csum[cins-1]->SetFillColor(10); |
| 303 |
csum[cins-1]->Range(0,0,1,1); |
csum[cins-1]->Range(0,0,1,1); |
| 304 |
fromfile.str(""); |
fromfile.str(""); |
| 305 |
fromfile<<"FTrkScanQLook_EXPERT File: "<<ffile<<" ----> Sum of "<<totsum<<" events after the "<<cins<<" calibration "; |
fromfile<<"FTrkScanQLook_EXPERT File: "<<ffile<<" ----> Sum of "<<totsum<<" events after the "<<cins<<" calibration at OBT= "<<hobt[(cod->Get(pctp->RunHeader))-1]; |
| 306 |
t->SetTextSize(0.02); |
t->SetTextSize(0.02); |
| 307 |
t->DrawLatex(0.02,0.98,fromfile.str().c_str()); |
t->DrawLatex(0.02,0.98,fromfile.str().c_str()); |
| 308 |
|
|
| 880 |
if(nn==0){ |
if(nn==0){ |
| 881 |
b.SetFillColor(107); |
b.SetFillColor(107); |
| 882 |
b.SetFillStyle(3945); |
b.SetFillStyle(3945); |
| 883 |
|
b.DrawBox(256.,-500.,384.,4500); |
| 884 |
b.DrawBox(768.,-500.,2047.,4500.); |
b.DrawBox(768.,-500.,2047.,4500.); |
| 885 |
} |
} |
| 886 |
else if(nn==1){ |
else if(nn==1){ |
| 891 |
b.SetFillColor(107); |
b.SetFillColor(107); |
| 892 |
b.SetFillStyle(3954); |
b.SetFillStyle(3954); |
| 893 |
b.DrawBox(384.,-500.,512.,4500.); |
b.DrawBox(384.,-500.,512.,4500.); |
| 894 |
|
b.DrawBox(2048.,-500.,2432.,4500.); |
| 895 |
b.DrawBox(2816.,-500.,2944.,4500.); |
b.DrawBox(2816.,-500.,2944.,4500.); |
| 896 |
b.DrawBox(2048.,-500.,2176.,4500.); |
} |
| 897 |
|
else if(nn==3){ |
| 898 |
|
b.SetFillColor(107); |
| 899 |
|
b.SetFillStyle(3954); |
| 900 |
|
b.DrawBox(2816.,-500.,3070.,4500.); |
| 901 |
} |
} |
| 902 |
else if(nn==4){ |
else if(nn==4){ |
| 903 |
b.SetFillColor(107); |
b.SetFillColor(107); |
| 904 |
b.SetFillStyle(3954); |
b.SetFillStyle(3954); |
| 905 |
b.DrawBox(384.,-500.,512.,4500.); |
b.DrawBox(256.,-500.,512.,4500.); |
| 906 |
|
b.DrawBox(2816.,-500.,3070.,4500.); |
| 907 |
|
} |
| 908 |
|
else if(nn==5){ |
| 909 |
|
b.SetFillColor(107); |
| 910 |
|
b.SetFillStyle(3954); |
| 911 |
|
b.DrawBox(896.,-500.,1024.,4500.); |
| 912 |
} |
} |
| 913 |
else if(nn==6){ |
else if(nn==6){ |
|
b.SetFillColor(6); |
|
|
b.SetFillStyle(3945); |
|
|
b.DrawBox(2560.,-500.,2816.,4500.); |
|
|
b.DrawBox(1024.,-500.,1280.,4500.); |
|
|
|
|
| 914 |
b.SetFillColor(107); |
b.SetFillColor(107); |
| 915 |
b.SetFillStyle(3954); |
b.SetFillStyle(3954); |
| 916 |
b.DrawBox(512.,-500.,768.,4500.); |
b.DrawBox(512.,-500.,768.,4500.); |
| 917 |
|
b.DrawBox(1024.,-500.,1280.,4500.); |
| 918 |
b.DrawBox(1280.,-500.,1792.,4500.); |
b.DrawBox(1280.,-500.,1792.,4500.); |
| 919 |
|
b.DrawBox(2560.,-500.,2816.,4500.); |
| 920 |
} |
} |
| 921 |
else if(nn==7){ |
else if(nn==7){ |
| 922 |
b.SetFillColor(107); |
b.SetFillColor(107); |
| 923 |
b.SetFillStyle(3954); |
b.SetFillStyle(3954); |
| 924 |
b.DrawBox(512.,-500.,768.,4500.); |
b.DrawBox(512.,-500.,768.,4500.); |
| 925 |
|
b.DrawBox(896.,-500.,1535.,4500.); |
| 926 |
|
b.DrawBox(2024.,-500.,2280.,4500.); |
| 927 |
} |
} |
| 928 |
else if(nn==8){ |
else if(nn==8){ |
| 929 |
b.SetFillColor(107); |
b.SetFillColor(107); |
| 933 |
else if(nn==9){ |
else if(nn==9){ |
| 934 |
b.SetFillColor(107); |
b.SetFillColor(107); |
| 935 |
b.SetFillStyle(3954); |
b.SetFillStyle(3954); |
| 936 |
|
b.DrawBox(0.,-500.,128.,4500.); |
| 937 |
b.DrawBox(256.,-500.,384.,4500.); |
b.DrawBox(256.,-500.,384.,4500.); |
| 938 |
|
b.DrawBox(512.,-500.,640.,4500.); |
| 939 |
|
b.DrawBox(896.,-500.,1024.,4500.); |
| 940 |
b.DrawBox(1280.,-500.,1535.,4500.); |
b.DrawBox(1280.,-500.,1535.,4500.); |
| 941 |
b.DrawBox(1792.,-500.,1920.,4500.); |
b.DrawBox(1792.,-500.,1920.,4500.); |
| 942 |
} |
} |
| 943 |
else if(nn==10){ |
else if(nn==10){ |
| 944 |
b.SetFillColor(107); |
b.SetFillColor(107); |
| 945 |
b.SetFillStyle(3954); |
b.SetFillStyle(3954); |
| 946 |
b.DrawBox(2048.,-500.,3070.,4500.); |
b.DrawBox(0.,-500.,256.,4500.); |
| 947 |
|
b.DrawBox(1024.,-500.,1152.,4500.); |
| 948 |
|
b.DrawBox(1768.,-500.,3070.,4500.); |
| 949 |
} |
} |
| 950 |
else if(nn==11){ |
else if(nn==11){ |
| 951 |
b.SetFillColor(6); |
b.SetFillColor(6); |
| 956 |
b.SetFillStyle(3954); |
b.SetFillStyle(3954); |
| 957 |
b.DrawBox(0.,-500.,512.,4500.); |
b.DrawBox(0.,-500.,512.,4500.); |
| 958 |
b.DrawBox(1920.,-500.,2560.,4500.); |
b.DrawBox(1920.,-500.,2560.,4500.); |
| 959 |
|
b.DrawBox(2816.,-500.,3070.,4500.); |
| 960 |
} |
} |
| 961 |
for(int va=1; va<24; va++){ |
for(int va=1; va<24; va++){ |
| 962 |
va1x=128*va; |
va1x=128*va; |