Changeset 2274 for trunk/MagicSoft/Mars/macros
- Timestamp:
- 07/12/03 22:01:34 (21 years ago)
- Location:
- trunk/MagicSoft/Mars/macros
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/macros/status.C
r2226 r2274 31 31 ///////////////////////////////////////////////////////////////////////////// 32 32 33 void status(const char *fname=" cosmics.root")33 void status(const char *fname="*1947*cosmic*.root") 34 34 { 35 35 // … … 64 64 plist.AddToList(&geomcam); 65 65 66 /* 67 MSrcPosCam src; 68 src.SetXY(1./geomcam.GetConvMm2Deg(), 0); 69 plist.AddToList(&src); 70 */ 71 66 72 // 67 73 // Now setup the tasks and tasklist: … … 78 84 MCerPhotCalc ncalc; 79 85 80 MBlindPixelCalc blind; 86 TArrayS blinds(2); 87 blinds[0] = 271; 88 blinds[1] = 291; 89 90 MBlindPixelCalc blind; 91 //blind.SetPixelIndices(blinds); 81 92 blind.SetUseInterpolation(); 82 93 … … 87 98 MCT1SupercutsCalc calc1; 88 99 100 MHCamEvent hist("PedestalRms"); 101 hist.SetType(1); 102 plist.AddToList(&hist); 103 89 104 // ------------------------------------------- 90 105 MFillH hfill0("Uncleaned [MHCamEvent]", "MCerPhotEvt"); 91 MFillH hfill1("MHHillas", "MHillas"); 92 MFillH hfill2("MHHillasExt"); 93 MFillH hfill3("MHHillasExtSrc [MHHillasExt]", "MHillasSrc"); 94 MFillH hfill4("MHHillasSrc","MHillasSrc"); 95 MFillH hfill5("MHNewImagePar","MNewImagePar"); 96 MFillH hfill6("MHStarMap", "MHillas"); 97 MFillH hfill7("Cleaned [MHCamEvent]", "MCerPhotEvt"); 98 MFillH hfill8("MHHadronness", "MHadronness"); 99 MFillH hfill9("MHSigmaTheta"); 106 MFillH hfill1("Pedestals [MHCamEvent]", "MPedestalCam"); 107 MFillH hfill2("PedestalRms", "MPedestalCam"); 108 MFillH hfill3("MHHillas", "MHillas"); 109 MFillH hfill4("MHHillasExt"); 110 MFillH hfill5("MHHillasExtSrc [MHHillasExt]", "MHillasSrc"); 111 MFillH hfill6("MHHillasSrc","MHillasSrc"); 112 MFillH hfill7("MHNewImagePar","MNewImagePar"); 113 MFillH hfill8("MHStarMap", "MHillas"); 114 MFillH hfill9("Cleaned [MHCamEvent]", "MCerPhotEvt"); 115 MFillH hfill10("MHHadronness", "MHadronness"); 116 MFillH hfill11("MHSigmaTheta"); 100 117 101 118 tlist.AddToList(&read); … … 103 120 tlist.AddToList(&pnsb); 104 121 tlist.AddToList(&ncalc); 122 tlist.AddToList(&blind); 105 123 tlist.AddToList(&hfill0); 106 tlist.AddToList(&blind);107 124 //tlist.AddToList(&sgcal); 108 125 tlist.AddToList(&clean); … … 117 134 tlist.AddToList(&hfill6); 118 135 tlist.AddToList(&hfill7); 119 //tlist.AddToList(&hfill8); 136 tlist.AddToList(&hfill8); 137 tlist.AddToList(&hfill9); 138 //tlist.AddToList(&hfill10); 120 139 121 140 MEvtLoop evtloop; … … 131 150 tlist.PrintStatistics(); 132 151 152 MHCamera &uncl = *((MHCamEvent*)plist.FindObject("Uncleaned"))->GetHistByName(); 153 MHCamera &hped = *((MHCamEvent*)plist.FindObject("Pedestals"))->GetHistByName(); 154 MHCamera &hrms = *((MHCamEvent*)plist.FindObject("PedestalRms"))->GetHistByName(); 155 156 for (int i=0; i<577; i++) 157 { 158 if (uncl.IsUsed(i)) 159 { 160 if (uncl[i+1]>uncl.GetMean()+3*uncl.GetRMS()) 161 cout << "Mean Charge of Pixel-Index #" << i << ": " << uncl[i+1] << " > 3*rms" << endl; 162 if (uncl[i+1]==0) 163 cout << "Mean Charge of Pixel-Index #" << i << ": " << uncl[i+1] << " <= 0" << endl; 164 if (uncl[i+1]<uncl.GetMean()-3*uncl.GetRMS()) 165 cout << "Mean Charge of Pixel-Index #" << i << ": " << uncl[i+1] << " < 3*rms" << endl; 166 } 167 if (hped.IsUsed(i)) 168 { 169 if (hped[i+1]>hped.GetMean()+1.5*hped.GetRMS()) 170 cout << "Mean Pedestal of Pixel-Index #" << i << ": " << hped[i+1] << " > 1.5*rms" << endl; 171 if (hped[i+1]==0) 172 cout << "Mean Pedestal of Pixel-Index #" << i << ": " << hped[i+1] << " <= 0" << endl; 173 if (hped[i+1]<hped.GetMean()-1.5*hped.GetRMS()) 174 cout << "Mean Pedestal of Pixel-Index #" << i << ": " << hped[i+1] << " < 1.5*rms" << endl; 175 } 176 if (hrms.IsUsed(i)) 177 { 178 if (hrms[i+1]>hrms.GetMean()+4*hrms.GetRMS()) 179 cout << "Mean PedestalRMS of Pixel-Index #" << i << ": " << hrms[i+1] << " > 4*rms" << endl; 180 if (hrms[i+1]==0) 181 cout << "Mean PedestalRMS of Pixel-Index #" << i << ": " << hrms[i+1] << " <= 0" << endl; 182 if (hrms[i+1]<hrms.GetMean()-4*hrms.GetRMS()) 183 cout << "Mean PedestalRMS of Pixel-Index #" << i << ": " << hrms[i+1] << " < 4*rms" << endl; 184 } 185 } 186 133 187 // 134 188 // Make sure the display hasn't been deleted by the user while the … … 138 192 { 139 193 // Save data in a postscriptfile (status.ps) 140 d->SaveAsPS();194 //d->SaveAsPS(); 141 195 /* 142 196 * ----------- Write status to a root file ------------ -
trunk/MagicSoft/Mars/macros/sumevents.C
r2265 r2274 90 90 disp3->SetYTitle("\\sigma_{S} [%]"); 91 91 92 disp1->SetOptStat(1111);93 disp2->SetOptStat(1101);94 disp3->SetOptStat(1101);92 TText text(0.1, 0.5, &fname[fname.Last('/')+1]); 93 text.SetTextSize(0.015); 94 text.DrawClone(); 95 95 96 96 c->cd(1); 97 gStyle->SetOptStat(1111); 97 98 disp1->Draw("hist"); 99 gPad->Update(); 98 100 99 101 c->cd(2); 100 102 gPad->SetLogy(); 103 gStyle->SetOptStat(1101); 101 104 disp2->Draw("hist"); 105 gPad->Update(); 102 106 103 107 c->cd(3); 104 108 gPad->SetLogy(); 109 gStyle->SetOptStat(1101); 105 110 disp3->Draw("hist"); 111 gPad->Update(); 106 112 107 113 c->cd(4); 108 114 gPad->SetBorderMode(0); 109 TText text(0.1, 0.95, &fname[fname.Last('/')+1]);110 text.SetTextSize(0.03);111 text.DrawClone();112 115 gPad->Divide(1,1); 113 116 gPad->cd(1); -
trunk/MagicSoft/Mars/macros/sumeventserr.C
r2265 r2274 93 93 disp3->SetYTitle("\\sigma_{S_{err}} [%]"); 94 94 95 disp1->SetOptStat(1111); 96 disp2->SetOptStat(1101); 97 disp3->SetOptStat(1101); 95 TText text(0.1, 0.5, &fname[fname.Last('/')+1]); 96 text.SetTextSize(0.015); 97 text.DrawClone(); 98 99 c->cd(1); 100 gStyle->SetOptStat(1111); 101 disp1->Draw("hist"); 102 gPad->Update(); 103 104 c->cd(2); 105 gPad->SetLogy(); 106 gStyle->SetOptStat(1101); 107 disp2->Draw("hist"); 108 gPad->Update(); 109 110 c->cd(3); 111 gPad->SetLogy(); 112 gStyle->SetOptStat(1101); 113 disp3->Draw("hist"); 114 gPad->Update(); 98 115 99 116 c->cd(4); 100 117 gPad->SetBorderMode(0); 101 TText text(0.1, 0.95, &fname[fname.Last('/')+1]);102 text.SetTextSize(0.03);103 text.DrawClone();104 118 gPad->Divide(1,1); 105 119 gPad->cd(1); … … 117 131 gPad->cd(1); 118 132 disp3->Draw(); 119 120 c->cd(1);121 disp1->Draw("hist");122 123 c->cd(2);124 gPad->SetLogy();125 disp2->Draw("hist");126 127 c->cd(3);128 gPad->SetLogy();129 disp3->Draw("hist");130 133 131 134 c->SaveAs(fname(0, fname.Last('.')+1) + "ps"); -
trunk/MagicSoft/Mars/macros/sumeventsrms.C
r2252 r2274 100 100 disp3->SetYTitle("rel.err [%]"); 101 101 102 TText text(0.1, 0.5, &fname[fname.Last('/')+1]); 103 text.SetTextSize(0.015); 104 text.DrawClone(); 105 106 c->cd(1); 107 disp1->Draw("hist"); 108 109 c->cd(2); 110 gPad->SetLogy(); 111 disp2->Draw("hist"); 112 113 c->cd(3); 114 gPad->SetLogy(); 115 disp3->Draw("hist"); 116 102 117 c->cd(4); 103 118 gPad->SetBorderMode(0); 104 TText text(0.1, 0.95, &fname[fname.Last('/')+1]);105 text.SetTextSize(0.03);106 text.DrawClone();107 119 gPad->Divide(1,1); 108 120 gPad->cd(1); … … 120 132 gPad->cd(1); 121 133 disp3->Draw(); 122 123 c->cd(1);124 disp1->Draw("hist");125 126 c->cd(2);127 gPad->SetLogy();128 disp2->Draw("hist");129 130 c->cd(3);131 gPad->SetLogy();132 disp3->Draw("hist");133 134 134 135 c->SaveAs(fname(0, fname.Last('.')+1) + "ps"); -
trunk/MagicSoft/Mars/macros/sumpedestalrms.C
r2265 r2274 94 94 disp3->SetYTitle("\\sigma_{P_{rms}} [%]"); 95 95 96 disp1->SetOptStat(1111);97 disp2->SetOptStat(1101);98 disp3->SetOptStat(1101);96 TText text(0.1, 0.5, &fname[fname.Last('/')+1]); 97 text.SetTextSize(0.015); 98 text.DrawClone(); 99 99 100 100 c->cd(1); 101 gStyle->SetOptStat(1111); 101 102 disp1->Draw("hist"); 103 gPad->Update(); 102 104 103 105 c->cd(2); 106 gStyle->SetOptStat(1101); 104 107 disp2->Draw("hist"); 108 gPad->Update(); 105 109 106 110 c->cd(3); 111 gStyle->SetOptStat(1101); 107 112 disp3->Draw("hist"); 113 gPad->Update(); 108 114 109 115 c->cd(4); 110 116 gPad->SetBorderMode(0); 111 TText text(0.1, 0.95, &fname[fname.Last('/')+1]);112 text.SetTextSize(0.03);113 text.DrawClone();114 117 gPad->Divide(1,1); 115 118 gPad->cd(1); -
trunk/MagicSoft/Mars/macros/sumpedestals.C
r2265 r2274 90 90 disp3->SetYTitle("\\sigma_{P} [%]"); 91 91 92 disp1->SetOptStat(1111);93 disp2->SetOptStat(1101);94 disp3->SetOptStat(1101);92 TText text(0.1, 0.5, &fname[fname.Last('/')+1]); 93 text.SetTextSize(0.015); 94 text.DrawClone(); 95 95 96 96 c->cd(1); 97 gStyle->SetOptStat(1111); 97 98 disp1->Draw("hist"); 99 gPad->Update(); 98 100 99 101 c->cd(2); 102 gStyle->SetOptStat(1101); 100 103 disp2->Draw("hist"); 104 gPad->Update(); 101 105 102 106 c->cd(3); 107 gStyle->SetOptStat(1101); 103 108 disp3->Draw("hist"); 109 gPad->Update(); 104 110 105 111 c->cd(4); 106 112 gPad->SetBorderMode(0); 107 TText text(0.1, 0.95, &fname[fname.Last('/')+1]);108 text.SetTextSize(0.03);109 text.DrawClone();110 113 gPad->Divide(1,1); 111 114 gPad->cd(1);
Note:
See TracChangeset
for help on using the changeset viewer.