Changeset 2529
- Timestamp:
- 11/19/03 00:03:53 (21 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r2528 r2529 3 3 4 4 -*-*- END OF LINE -*-*- 5 2003/11/18: Thomas Bretz 6 7 * mars.cc: 8 - changed Usage to standard Usage 9 10 * merpp.cc, mona.cc, readraw.cc, star.cc, status.cc, 11 mbase/MArgs.[h,cc]: 12 - removed const-qualifier for argv 13 14 * mbase/MTask.cc: 15 - fixed a bug in PrintStatistics (setfill was not set) 16 17 * mbase/MTaskList.cc: 18 - simplified PrintStatistics 19 20 * mbase/MTime.h: 21 - added Getter 22 23 * mfileio/MReadTree.cc: 24 - remove a leading "*" when checking whether a branch which 25 should be enabled exists 26 27 * mfileio/MWriteRootFile.cc: 28 - fixed a crash when Print is called and GetTree() returns NULL 29 30 * mhist/MHEvent.cc: 31 - implemented more levels (MeV, GeV, etc) for energy display 32 33 * mraw/MRawSocketRead.cc: 34 - removed some obsolete comment 35 36 * mreport/MReport.[h,cc]: 37 - added FindTime 38 - removed an invalid line (ReadAngle) in the header file 39 - Set class version to 1 40 - do not write fTime '//!' 41 42 * mreport/MReportFileRead.cc: 43 - fixed handling of MTimes 44 45 46 5 47 2003/11/18: Abelardo Moralejo 6 48 … … 8 50 - Fixed missing initialization of fLongitmax 9 51 52 53 10 54 2003/11/18: Markus Gaug 11 55 12 56 * manalysis/MCalibrationCalc: 13 57 - performs the eventloop and fills the calibration classes 14 58 15 59 * manalysis/MCalibrationCam: 16 - holds the classes: MCalibrationPix and MCalibrationBlindPix and MCalibrationPINDiode 17 - one MCalibrationPix per pixel 60 - holds the classes: MCalibrationPix and MCalibrationBlindPix 61 and MCalibrationPINDiode 62 - one MCalibrationPix per pixel 18 63 19 64 * manalysis/MCalibrationPix: 20 21 65 - holds the fit results and conversion factors, etc per pixel 66 - hold histograms MHCalibrationPixel 22 67 23 68 * manalysis/MCalibrationBlindPix: 24 25 69 - holds fit results and derived number of photons, etc 70 - hold histogram MHCalibrationBlindPixel 26 71 27 72 * manalysis/MCalibrationPINDiode: 28 29 73 - holds fit results and derived number of photons, etc 74 - hold histogram MHCalibrationPINDiode 30 75 31 76 * mhist/MHCalibrationPix: 32 - histograms with sum of charges, time slices and reduced charges vs. event number 33 - fit functions 77 - histograms with sum of charges, time slices and reduced 78 charges vs. event number 79 - fit functions 34 80 35 81 * mhist/MHCalibrationPixel: 36 - histograms with sum of charges, time slices and reduced charges vs. event number 37 - fit functions 82 - histograms with sum of charges, time slices and reduced 83 charges vs. event number 84 - fit functions 38 85 39 86 * mhist/MHCalibrationBlindPixel: 40 - histograms with sum of charges, time slices and reduced charges vs. event number 41 - fit functions 87 - histograms with sum of charges, time slices and reduced 88 charges vs. event number 89 - fit functions 42 90 43 91 * mhist/MHCalibrationPINDiode: 44 - histograms with sum of charges, time slices and reduced charges vs. event number 45 - fit functions 46 47 *mhist/MH: 48 - new function: CutEdges 49 50 *macros/calibration.C 51 - simple macro showing the functionning 52 53 92 - histograms with sum of charges, time slices and reduced 93 charges vs. event number 94 - fit functions 95 96 * mhist/MH: 97 - new function: CutEdges 98 99 * macros/calibration.C 100 - simple macro showing the functionning 101 102 103 54 104 2003/11/17: Thomas Bretz 55 105 -
trunk/MagicSoft/Mars/mbase/MArgs.cc
r2377 r2529 54 54 // fArgv: A TList containing all other command line arguments 55 55 // 56 MArgs::MArgs(int argc, const char **argv) : fArgc(argc) 57 { 56 MArgs::MArgs(int argc, char **argv) : fArgc(argc) 57 { 58 // FIXME: argv has no const-qualifier to be idetical with 59 // TApplication. 58 60 fName = argv[0]; 59 61 -
trunk/MagicSoft/Mars/mbase/MArgs.h
r2275 r2529 31 31 32 32 public: 33 MArgs(int argc, c onst char **argv);33 MArgs(int argc, char **argv); 34 34 ~MArgs(); 35 35 -
trunk/MagicSoft/Mars/mbase/MTask.cc
r2490 r2529 328 328 void MTask::PrintStatistics(const Int_t lvl, Bool_t title) const 329 329 { 330 *fLog << all << set w(lvl) << " " << GetDescriptor() << "\t";330 *fLog << all << setfill(' ') << setw(lvl) << " " << GetDescriptor() << "\t"; 331 331 *fLog << dec << fNumExecutions; 332 332 if (fFilter) -
trunk/MagicSoft/Mars/mbase/MTaskList.cc
r2470 r2529 592 592 } 593 593 else 594 { 595 *fLog << setw(lvl) << " " << GetDescriptor(); 596 if (title) 597 *fLog << "\t" << fTitle; 598 *fLog << endl; 599 } 594 MTask::PrintStatistics(lvl, title); 600 595 601 596 // -
trunk/MagicSoft/Mars/mbase/MTime.h
r2461 r2529 83 83 } 84 84 85 void SetTime(Byte_t h, Byte_t m, Byte_t s, U Short_t ns)85 void SetTime(Byte_t h, Byte_t m, Byte_t s, UInt_t ns) 86 86 { 87 87 fHour = h; … … 114 114 return operator double(); 115 115 } 116 117 Byte_t GetHour() const { return fHour; } 118 Byte_t GetMin() const { return fMin; } 119 Byte_t GetSec() const { return fSec; } 120 UInt_t GetNanoSec() const { return fNanoSec; } 116 121 117 122 ClassDef(MTime, 2) //A generalized MARS time stamp -
trunk/MagicSoft/Mars/mfileio/MReadTree.cc
r2470 r2529 409 409 // Check whether this branch really exists 410 410 // 411 if (fChain->GetBranch(name)) 411 TString bn(name); 412 if (bn.EndsWith("*")) 413 bn.Remove(bn.Length()-1); 414 415 if (fChain->GetBranch(bn)) 412 416 SetBranchStatus(name, status); 413 417 … … 905 909 } 906 910 911 TString MReadTree::GetTreeName() const 912 { 913 return fChain->GetName(); 914 } 915 907 916 // -------------------------------------------------------------------------- 908 917 // -
trunk/MagicSoft/Mars/mfileio/MWriteRootFile.cc
r2470 r2529 161 161 MRootFileBranch *b = (MRootFileBranch*)obj; 162 162 163 if ( b->GetTree()->TestBit(kIsNewTree))163 if (!b->GetTree() || b->GetTree()->TestBit(kIsNewTree)) 164 164 continue; 165 165 -
trunk/MagicSoft/Mars/mhist/MHEvent.cc
r2512 r2529 226 226 s.Insert(0, txt); 227 227 228 s += "}{ ";229 s += " E="; 228 s += "}{ E="; 229 230 230 if (fMcEvt->GetEnergy()>1000) 231 231 s += Form("%.1fTeV", fMcEvt->GetEnergy()/1000); 232 232 else 233 s += Form("%dGeV", fMcEvt->GetEnergy()+.5); 233 if (fMcEvt->GetEnergy()>10) 234 s += Form("%dGeV", (Int_t)(fMcEvt->GetEnergy()+.5)); 235 else 236 if (fMcEvt->GetEnergy()>1) 237 s += Form("%.1fGeV", fMcEvt->GetEnergy()); 238 else 239 s += Form("%dMeV", (Int_t)(fMcEvt->GetEnergy()*1000+.5)); 240 234 241 s += " r="; 235 242 s += (int)(fMcEvt->GetImpact()/100+.5); 236 s += "m Z A=";243 s += "m Zd="; 237 244 s += (int)(fMcEvt->GetTheta()*180/TMath::Pi()+.5); 238 s += "\xb0 "; 239 s += fMcEvt->GetPhotElfromShower(); 240 s += "PhEl"; 241 s += "}"; 245 s += "\\circ "; 246 if (fMcEvt->GetPhotElfromShower()>=10000) 247 s += Form("%dk", (Int_t)(fMcEvt->GetPhotElfromShower()/1000.+.5)); 248 else 249 if (fMcEvt->GetPhotElfromShower()>=1000) 250 s += Form("%.1fk", fMcEvt->GetPhotElfromShower()/1000.); 251 else 252 s += fMcEvt->GetPhotElfromShower(); 253 s += "PhEl}"; 242 254 } 243 255 -
trunk/MagicSoft/Mars/mraw/MRawSocketRead.cc
r2496 r2529 135 135 136 136 *fLog << err << "ERROR - Cannot open port #" << fPort << endl; 137 137 138 return kFALSE; 138 139 } … … 187 188 fEvtNumber = (UInt_t)-1; 188 189 189 /*190 MEvtLoop *loop=(MEvtLoop*)pList->FindObject("Evtloop");191 if (loop)192 loop->SetProgressBar((TGProgressBar*)NULL);193 */194 190 return kTRUE; 195 191 } -
trunk/MagicSoft/Mars/mreport/MReport.cc
r2523 r2529 33 33 34 34 #include "MTime.h" 35 #include "MParList.h" 35 36 36 37 ClassImp(MReport); … … 82 83 return kTRUE; 83 84 } 85 86 MTime *MReport::FindTime(MParList &plist) 87 { 88 fTime = NULL; 89 90 TString id(ClassName()); 91 if (!id.BeginsWith("MReport")) 92 { 93 *fLog << warn << " WARNING - Class name '" << id << "' "; 94 *fLog << " doesn't begin with 'MReport'... no MTime assigned." << endl; 95 return NULL; 96 } 97 98 id.Remove(0, 7); 99 if (id.IsNull()) 100 { 101 *fLog << warn << " WARNING - No postfix existing... no MTime assigned." << endl; 102 return NULL; 103 } 104 105 id.Prepend("MTime"); 106 107 fTime = (MTime*)plist.FindCreateObj("MTime", id); 108 return fTime; 109 } -
trunk/MagicSoft/Mars/mreport/MReport.h
r2520 r2529 7 7 8 8 class MTime; 9 class MParList; 9 10 10 11 class MReport : public MParContainer … … 14 15 15 16 Byte_t fState; 16 MTime *fTime; 17 MTime *fTime; //! 17 18 18 19 ULong_t Hash() const { return fIdentifier.Hash(); } … … 39 40 void SetTime(MTime *t) { fTime = t; } 40 41 41 static Bool_t ReadAngle(TString &str, Double_t &ret);42 MTime *FindTime(MParList &plist); 42 43 43 ClassDef(MReport, 0) // Base class for control reports44 ClassDef(MReport, 1) // Base class for control reports 44 45 }; 45 46 -
trunk/MagicSoft/Mars/mreport/MReportFileRead.cc
r2523 r2529 60 60 ULong_t Hash() const { return fReport->GetIdentifier().Hash(); } 61 61 MReport *GetReport() { return fReport; } 62 void SetTime(MTime *t) { fReport->SetTime(t); }62 //void SetTime(MTime *t) { fReport->SetTime(t); } 63 63 Bool_t Interprete(TString &str) 64 64 { … … 69 69 return kTRUE; 70 70 } 71 void SetTime(MParList &plist) { fReport->FindTime(plist); } 72 void AddToList(MParList &plist) { plist.AddToList(fReport); } 71 73 }; 72 74 … … 178 180 Int_t MReportFileRead::PreProcess(MParList *pList) 179 181 { 180 MTime *time = (MTime*)pList->FindCreateObj("MTime"); 181 if (!time) 182 return kFALSE; 183 184 fList->ForEach(MReportHelp, SetTime)(time); 182 //MTime *time = (MTime*)pList->FindCreateObj("MTime"); 183 //if (!time) 184 // return kFALSE; 185 186 fList->ForEach(MReportHelp, SetTime)(*pList); 187 fList->ForEach(MReportHelp, AddToList)(*pList); 185 188 186 189 // … … 249 252 fIn->close(); 250 253 254 if (!GetNumExecutions()) 255 return kTRUE; 256 251 257 *fLog << inf << endl; 252 258 *fLog << GetDescriptor() << " statistics:" << endl;
Note:
See TracChangeset
for help on using the changeset viewer.