Changeset 6514
- Timestamp:
- 02/16/05 10:47:00 (20 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r6513 r6514 21 21 22 22 -*-*- END OF LINE -*-*- 23 24 2005/02/16 Abelardo Moralejo 25 26 * macros/starmc2.C: 27 - Changed the way in which the "OriginalMC" tree is copied from 28 the input to the output file. Now we ise the new procedure 29 MWriteRootFile::AddCopySource 30 23 31 24 32 2005/02/16 Thomas Bretz -
trunk/MagicSoft/Mars/macros/starmc2.C
r6403 r6514 38 38 void starmc2() 39 39 { 40 Char_t* AnalysisFilename = "calibrated_gamma_train.root"; // File to be analyzed41 //Char_t* AnalysisFilename = "calibrated_gamma_test.root"; // File to be analyzed40 // Char_t* AnalysisFilename = "calibrated_gamma_train.root"; // File to be analyzed 41 Char_t* AnalysisFilename = "calibrated_gamma_test.root"; // File to be analyzed 42 42 43 43 TString* OutFilename; 44 44 45 45 // Output file name 46 OutFilename = new TString("star_gamma_train.root"); // Output file name47 //OutFilename = new TString("star_gamma_test.root"); // Output file name46 // OutFilename = new TString("star_gamma_train.root"); // Output file name 47 OutFilename = new TString("star_gamma_test.root"); // Output file name 48 48 49 MImgCleanStd clean(4.5, 3.); // Applies tail cuts to image. 49 MImgCleanStd clean(10., 5.); // Applies tail cuts to image. 50 clean.SetMethod(MImgCleanStd::kAbsolute); 51 50 52 // WARNING: the tightness of the tail cuts depends on the signal extraction method 51 53 // used in mccalibrate.C!! (some methods result in positively biased signals) … … 119 121 write.AddContainer("MConcentration","Events"); 120 122 123 // 124 // Next line makes that the tree "OriginalMC" containing the MMcEvtBasic 125 // container for all produced Corsika events from which the events in the 126 // normal "Events" tree derive: 127 // 128 write.AddCopySource("OriginalMC"); 129 121 130 tlist.AddToList(&write); 122 131 … … 136 145 tlist.PrintStatistics(); 137 146 138 ////////////////////////////////////////////////////////////////////139 //140 // Second event loop: simply copy the tree MMcEvtBasic in the tree141 // "OriginalMC" from the input file to the output file:142 143 MParList plist2;144 MTaskList tlist2;145 146 plist2.AddToList(&tlist2);147 148 MReadMarsFile read2("OriginalMC");149 read2.AddFile(AnalysisFilename);150 read2.DisableAutoScheme();151 152 tlist2.AddToList(&read2);153 154 MWriteRootFile writeOrig(OutFilename->Data(),"UPDATE");155 writeOrig.AddContainer("MMcEvtBasic", "OriginalMC", kFALSE);156 157 tlist2.AddToList(&writeOrig);158 159 MEvtLoop evtloop2;160 bar.SetWindowName("Copying OriginalMC tree...");161 evtloop2.SetProgressBar(&bar);162 evtloop2.SetParList(&plist2);163 164 if (!evtloop2.Eventloop())165 return;166 167 tlist2.PrintStatistics();168 169 147 return; 170 148 }
Note:
See TracChangeset
for help on using the changeset viewer.