ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitProd/TreeFiller/src/FillMitTree.cc
(Generate patch)

Comparing UserCode/MitProd/TreeFiller/src/FillMitTree.cc (file contents):
Revision 1.5 by loizides, Tue Jun 24 14:25:46 2008 UTC vs.
Revision 1.64 by rwolf, Tue Jan 31 15:46:27 2012 UTC

# Line 2 | Line 2
2  
3   #include "MitProd/TreeFiller/interface/FillMitTree.h"
4   #include "FWCore/MessageLogger/interface/MessageLogger.h"
5 + #include "FWCore/ParameterSet/interface/ParameterSet.h"
6   #include "FWCore/ServiceRegistry/interface/Service.h"
7 < #include "MitProd/TreeService/interface/TreeService.h"
7 > #include "MitProd/ObjectService/interface/ObjectService.h"
8 > #include "MitProd/TreeFiller/interface/AssociationMaps.h"
9 > #include "MitProd/TreeFiller/interface/FillerBasicClusters.h"
10 > #include "MitProd/TreeFiller/interface/FillerBeamSpot.h"
11 > #include "MitProd/TreeFiller/interface/FillerCaloJets.h"
12 > #include "MitProd/TreeFiller/interface/FillerCaloMet.h"
13 > #include "MitProd/TreeFiller/interface/FillerCaloTaus.h"
14 > #include "MitProd/TreeFiller/interface/FillerCaloTowers.h"
15 > #include "MitProd/TreeFiller/interface/FillerConversions.h"
16 > #include "MitProd/TreeFiller/interface/FillerConversionsDecay.h"
17 > #include "MitProd/TreeFiller/interface/FillerDecayParts.h"
18 > #include "MitProd/TreeFiller/interface/FillerEmbedWeight.h"
19 > #include "MitProd/TreeFiller/interface/FillerElectrons.h"
20 > #include "MitProd/TreeFiller/interface/FillerEvtSelData.h"
21 > #include "MitProd/TreeFiller/interface/FillerGenJets.h"
22 > #include "MitProd/TreeFiller/interface/FillerGenMet.h"
23 > #include "MitProd/TreeFiller/interface/FillerJPTJets.h"
24 > #include "MitProd/TreeFiller/interface/FillerMCEventInfo.h"
25 > #include "MitProd/TreeFiller/interface/FillerMCParticles.h"
26 > #include "MitProd/TreeFiller/interface/FillerMCVertexes.h"
27 > #include "MitProd/TreeFiller/interface/FillerMet.h"
28   #include "MitProd/TreeFiller/interface/FillerMetaInfos.h"
29 < #include "MitProd/TreeFiller/interface/FillerGlobalMuons.h"
30 < #include "MitProd/TreeFiller/interface/FillerGenParts.h"
29 > #include "MitProd/TreeFiller/interface/FillerMetaInfos.h"
30 > #include "MitProd/TreeFiller/interface/FillerMuons.h"
31 > #include "MitProd/TreeFiller/interface/FillerPFCandidates.h"
32 > #include "MitProd/TreeFiller/interface/FillerPFJets.h"
33 > #include "MitProd/TreeFiller/interface/FillerPFMet.h"
34 > #include "MitProd/TreeFiller/interface/FillerPFTaus.h"
35 > #include "MitProd/TreeFiller/interface/FillerPhotons.h"
36 > #include "MitProd/TreeFiller/interface/FillerPileupInfo.h"
37 > #include "MitProd/TreeFiller/interface/FillerPileupEnergyDensity.h"
38 > #include "MitProd/TreeFiller/interface/FillerPixelHits.h"
39 > #include "MitProd/TreeFiller/interface/FillerStableParts.h"
40 > #include "MitProd/TreeFiller/interface/FillerStripHits.h"
41 > #include "MitProd/TreeFiller/interface/FillerSuperClusters.h"
42 > #include "MitProd/TreeFiller/interface/FillerTracks.h"
43 > #include "MitProd/TreeFiller/interface/FillerTrackJets.h"
44 > #include "MitProd/TreeFiller/interface/FillerVertexes.h"
45 > #include "MitAna/DataTree/interface/Names.h"
46 > #include "MitAna/DataTree/interface/BranchTable.h"
47 > #include "MitCommon/OptIO/interface/OptInt.h"
48  
49   using namespace std;
50   using namespace edm;
51   using namespace mithep;
52  
53 < //-------------------------------------------------------------------------------------------------
54 < FillMitTree::FillMitTree(const edm::ParameterSet &cfg)
53 > mithep::ObjectService *mithep::FillMitTree::os_ = 0;
54 >
55 > //--------------------------------------------------------------------------------------------------
56 > FillMitTree::FillMitTree(const edm::ParameterSet &cfg) :
57 >  defactive_(cfg.getUntrackedParameter<bool>("defactive",1)),
58 >  brtable_(0),
59 >  acfnumber_(-1),
60 >  tws_(new TreeWriter(Names::gkEvtTreeName,0))
61   {
62 <  // Constructor: initialize fillers
62 >  // Constructor.
63  
64    if (!configure(cfg)) {
65      throw edm::Exception(edm::errors::Configuration, "FillMitTree::FillMitTree()\n")
# Line 23 | Line 67 | FillMitTree::FillMitTree(const edm::Para
67    }
68   }
69  
70 < //-------------------------------------------------------------------------------------------------
70 > //--------------------------------------------------------------------------------------------------
71   FillMitTree::~FillMitTree()
72   {
73 <  // Destructor: nothing to be done here.
73 >  // Destructor.
74 >
75 >  delete brtable_;
76 >  delete tws_;
77 > }
78 >
79 > //--------------------------------------------------------------------------------------------------
80 > bool FillMitTree::addActiveFiller(BaseFiller *bf)
81 > {
82 >  // Check if filler is active and add it to list of fillers. Otherwise delete it.
83 >
84 >  if (!bf)
85 >    return 0;
86 >
87 >  if (bf->Active()) {
88 >    fillers_.push_back(bf);
89 >    return 1;
90 >  }
91 >
92 >  delete bf;
93 >  bf = 0;
94 >  return 0;
95   }
96  
97 < //-------------------------------------------------------------------------------------------------
97 > //--------------------------------------------------------------------------------------------------
98 > void FillMitTree::beginRun(edm::Run const &run, edm::EventSetup const &setup)
99 > {
100 >  // Access and copy event content.
101 >
102 >  // first step: Loop over the data fillers of the various components
103 >  for (std::vector<BaseFiller*>::const_iterator iF = fillers_.begin(); iF != fillers_.end(); ++iF) {
104 >    (*iF)->FillRunBlock(run,setup);
105 >  }
106 >  
107 > }
108 >
109 > //--------------------------------------------------------------------------------------------------
110   void FillMitTree::analyze(const edm::Event      &event,
111                            const edm::EventSetup &setup)
112   {
113    // Access and copy event content.
114 +  
115 +  //tree writer begin event actions
116 +  tws_->BeginEvent(kTRUE);
117  
118 <  // First step: Loop over the data fillers of the various components
118 >  // first step: Loop over the data fillers of the various components
119    for (std::vector<BaseFiller*>::const_iterator iF = fillers_.begin(); iF != fillers_.end(); ++iF) {
120 +    //printf("%s FillDataBlock\n",(*iF)->Name().c_str());
121      (*iF)->FillDataBlock(event,setup);
122    }
123  
124 <  // Second step: Loop over the link resolution of the various components
124 >  // second step: Loop over the link resolution of the various components
125    for (std::vector<BaseFiller*>::const_iterator iF = fillers_.begin(); iF != fillers_.end(); ++iF) {
126 +    //printf("%s ResolveLinks\n",(*iF)->Name().c_str());
127      (*iF)->ResolveLinks(event,setup);
128    }
129 +
130 +  if (brtable_) { // only the first FillMitTree object has to deal with the branch table
131 +    if (acfnumber_==-1) {
132 +      brtable_->Rehash(brtable_->GetSize());
133 +      if (0)
134 +        brtable_->Print();
135 +    }
136 +    if (acfnumber_ != tws_->GetFileNumber()) {
137 +      tws_->StoreObject(brtable_);
138 +      acfnumber_ = tws_->GetFileNumber();
139 +    }
140 +  }
141 +
142 +  //tree writer end of event actions
143 +  tws_->EndEvent(kTRUE);
144   }
145  
146 < //-------------------------------------------------------------------------------------------------
147 < void FillMitTree::beginJob(const edm::EventSetup &event)
146 > //--------------------------------------------------------------------------------------------------
147 > void FillMitTree::beginJob()
148   {
149    // Access the tree and book branches.
150  
151 <  Service<TreeService> ts;
152 <  TreeWriter *tws = ts->get();
153 <  if (! tws) {
154 <    throw edm::Exception(edm::errors::Configuration, "FillMitTree::beginJob()\n")
155 <      << "Could not get pointer to tree." << "\n";
156 <    return;
151 >  if (os_==0) { // only the first FillMitTree object has to deal with this
152 >    Service<ObjectService> os;
153 >    if (!os.isAvailable()) {
154 >      throw edm::Exception(edm::errors::Configuration, "FillMitTree::beginJob()\n")
155 >        << "Could not get object service. "
156 >        << "Do you have the ObjectService defined in your config?" << "\n";
157 >      return;
158 >    }
159 >    os_ = &(*os);
160 >    brtable_ = new BranchTable;
161 >    brtable_->SetName(Names::gkBranchTable);
162 >    brtable_->SetOwner();
163 >    os->add(brtable_, brtable_->GetName());
164    }
165  
166 <  // Loop over the various components and book the branches
166 >  // loop over the various components and book the branches
167    for (std::vector<BaseFiller*>::iterator iF = fillers_.begin(); iF != fillers_.end(); ++iF) {
168 <    (*iF)->BookDataBlock(*tws);
168 >    edm::LogInfo("FillMitTree::beginJob") << "Booking for " << (*iF)->Name() << endl;
169 >    (*iF)->BookDataBlock(*tws_);
170    }
171 +
172 +  // call branch ref for the event tree
173 +  if (brtable_ && tws_->GetTree())
174 +    tws_->GetTree()->BranchRef();
175 +  
176   }
177  
178 < //-------------------------------------------------------------------------------------------------
178 > //--------------------------------------------------------------------------------------------------
179   bool FillMitTree::configure(const edm::ParameterSet &cfg)
180   {
71  // Configure our fillers.
181  
182 +  // Configure TreeWriter
183 +  const std::string twsConfigName("TreeWriter");
184 +  ParameterSet twsConfig;
185 +  if (cfg.existsAs<ParameterSet>(twsConfigName,0))
186 +    twsConfig = cfg.getUntrackedParameter<ParameterSet>(twsConfigName);
187 +  
188 +  configureTreeWriter(twsConfig);
189 +  
190 +  // Configure our fillers according to given parameter ("fillers").
191 +
192 +  std::vector<std::string> pars;
193 +  if (cfg.exists("fillers"))
194 +    pars=cfg.getUntrackedParameter<vector<string> >("fillers");
195 +  else
196 +    cfg.getParameterSetNames(pars, false);
197 +
198 +  // loop over psets
199 +  for (unsigned int i = 0; i<pars.size(); ++i) {
200 +
201 +    const string name(pars.at(i));
202 +
203 +    string ftype("Filler" + name);
204 +    if (cfg.existsAs<ParameterSet>(name,0)) {
205 +      ParameterSet next(cfg.getUntrackedParameter<ParameterSet>(name));
206 +      if (!next.exists("fillerType")) {
207 +        edm::LogError("FillMitTree") << "Cannot determine fillerType for pset named "
208 +                                     << name << std::endl;
209 +        throw edm::Exception(edm::errors::Configuration, "FillMitTree::configure\n")
210 +          << "Cannot determine fillerType for pset named "
211 +          << name << std::endl;
212 +      }
213 +      ftype = next.getUntrackedParameter<string>("fillerType");
214 +    }
215 +
216 +    edm::LogInfo("FillMitTree") << "Attempting to configure '" << ftype
217 +                                << "' for '" << name << "'" << std::endl;
218 +
219 +    if (ftype.compare("FillerMetaInfos")==0) {
220 +      FillerMetaInfos *fillerMetaInfos = new FillerMetaInfos(cfg, name.c_str(), defactive_);
221 +      addActiveFiller(fillerMetaInfos);
222 +      continue;
223 +    }
224 +
225 +    if (ftype.compare("FillerMCParticles")==0) {
226 +      FillerMCParticles *fillerMCParticles = new FillerMCParticles(cfg, name.c_str(), defactive_);
227 +      addActiveFiller(fillerMCParticles);
228 +      continue;
229 +    }
230 +
231 +    if (ftype.compare("FillerMCEventInfo")==0) {
232 +      FillerMCEventInfo *fillerMCEventInfo = new FillerMCEventInfo(cfg, name.c_str(), defactive_);
233 +      addActiveFiller(fillerMCEventInfo);
234 +      continue;
235 +    }
236 +
237 +    if (ftype.compare("FillerMCVertexes")==0) {
238 +      FillerMCVertexes *fillerMCVertexes = new FillerMCVertexes(cfg, name.c_str(), defactive_);
239 +      addActiveFiller(fillerMCVertexes);
240 +      continue;
241 +    }  
242 +
243 +    if (ftype.compare("FillerEvtSelData")==0) {
244 +      FillerEvtSelData *fillerEvtSelData = new FillerEvtSelData(cfg, name.c_str(), defactive_);
245 +      addActiveFiller(fillerEvtSelData);
246 +      continue;
247 +    }
248 +
249 +    if (ftype.compare("FillerBeamSpot")==0) {
250 +      FillerBeamSpot *fillerBeamSpot = new FillerBeamSpot(cfg, name.c_str(), defactive_);
251 +      addActiveFiller(fillerBeamSpot);
252 +      continue;
253 +    }
254 +
255 +    if (ftype.compare("FillerVertexes")==0) {
256 +      FillerVertexes *fillerVertexes = new FillerVertexes(cfg, name.c_str(), defactive_);
257 +      addActiveFiller(fillerVertexes);
258 +      continue;
259 +    }  
260 +
261 +    if (ftype.compare("FillerCaloTowers")==0) {
262 +      FillerCaloTowers *fillerCaloTowers = new FillerCaloTowers(cfg, name.c_str(), defactive_);
263 +      addActiveFiller(fillerCaloTowers);
264 +      continue;
265 +    }  
266 +
267 +    if (ftype.compare("FillerGenJets")==0) {
268 +      FillerGenJets *fillerGenJets = new FillerGenJets(cfg, name.c_str(), defactive_);
269 +      addActiveFiller(fillerGenJets);
270 +      continue;
271 +    }  
272 +
273 +    if (ftype.compare("FillerCaloJets")==0) {
274 +      FillerCaloJets *fillerCaloJets = new FillerCaloJets(cfg, name.c_str(), defactive_);
275 +      addActiveFiller(fillerCaloJets);
276 +      continue;
277 +    }  
278 +    
279 +    if (ftype.compare("FillerMet")==0) {
280 +      FillerMet *fillerMet = new FillerMet(cfg, name.c_str(), defactive_);
281 +      addActiveFiller(fillerMet);
282 +      continue;
283 +    }  
284 +    
285 +    if (ftype.compare("FillerGenMet")==0) {
286 +      FillerGenMet *fillerGenMet = new FillerGenMet(cfg, name.c_str(), defactive_);
287 +      addActiveFiller(fillerGenMet);
288 +      continue;
289 +    }  
290 +
291 +    if (ftype.compare("FillerCaloMet")==0) {
292 +      FillerCaloMet *fillerCaloMet = new FillerCaloMet(cfg, name.c_str(), defactive_);
293 +      addActiveFiller(fillerCaloMet);
294 +      continue;
295 +    }
296 +    
297 +    if (ftype.compare("FillerPFMet")==0) {
298 +      FillerPFMet *fillerPFMet = new FillerPFMet(cfg, name.c_str(), defactive_);
299 +      addActiveFiller(fillerPFMet);
300 +      continue;
301 +    }  
302 +
303 +    if (ftype.compare("FillerBasicClusters")==0) {
304 +      FillerBasicClusters *fillerBasicClusters =
305 +        new FillerBasicClusters(cfg, name.c_str(), defactive_);
306 +      addActiveFiller(fillerBasicClusters);
307 +      continue;
308 +    }  
309 +
310 +    if (ftype.compare("FillerSuperClusters")==0) {
311 +      FillerSuperClusters *fillerSuperClusters =  
312 +        new FillerSuperClusters(cfg, name.c_str(), defactive_);
313 +      addActiveFiller(fillerSuperClusters);
314 +      continue;
315 +    }  
316 +
317 +    if (ftype.compare("FillerPixelHits")==0) {
318 +      FillerPixelHits *fillerPixelHits =  
319 +        new FillerPixelHits(cfg, name.c_str(), defactive_);
320 +      addActiveFiller(fillerPixelHits);
321 +      continue;
322 +    }  
323 +
324 +    if (ftype.compare("FillerPileupInfo")==0) {
325 +      FillerPileupInfo *fillerPileupInfo =  
326 +        new FillerPileupInfo(cfg, name.c_str(), defactive_);
327 +      addActiveFiller(fillerPileupInfo);
328 +      continue;
329 +    }  
330 +
331 +    if (ftype.compare("FillerPileupEnergyDensity")==0) {
332 +      FillerPileupEnergyDensity *fillerPileupEnergyDensity =  
333 +        new FillerPileupEnergyDensity(cfg, name.c_str(), defactive_);
334 +      addActiveFiller(fillerPileupEnergyDensity);
335 +      continue;
336 +    }  
337 +
338 +    if (ftype.compare("FillerStripHits")==0) {
339 +      FillerStripHits *fillerStripHits =  
340 +        new FillerStripHits(cfg, name.c_str(), defactive_);
341 +      addActiveFiller(fillerStripHits);
342 +      continue;
343 +    }  
344 +
345 +    if (ftype.compare("FillerTracks")==0) {
346 +      FillerTracks *fillerTracks = new FillerTracks(cfg, name.c_str(), defactive_);
347 +      addActiveFiller(fillerTracks);
348 +      continue;
349 +    }  
350 +    if (ftype.compare("FillerMuons")==0) {
351 +      FillerMuons *fillerMuons = new FillerMuons(cfg, name.c_str(), defactive_);
352 +      addActiveFiller(fillerMuons);
353 +      continue;
354 +    }  
355 +    if (ftype.compare("FillerElectrons")==0) {
356 +      FillerElectrons *fillerElectrons = new FillerElectrons(cfg, name.c_str(), defactive_);
357 +      addActiveFiller(fillerElectrons);
358 +      continue;
359 +    }  
360 +    if (ftype.compare("FillerConversions")==0) {
361 +      FillerConversions *fillerConversions = new FillerConversions(cfg, name.c_str(), defactive_);
362 +      addActiveFiller(fillerConversions);
363 +      continue;
364 +    }
365 +    
366 +    if (ftype.compare("FillerConversionsDecay")==0) {
367 +      FillerConversionsDecay *fillerConversionsDecay = new FillerConversionsDecay(cfg, name.c_str(), defactive_);
368 +      addActiveFiller(fillerConversionsDecay);
369 +      continue;
370 +    }    
371 +
372 +    if (ftype.compare("FillerPhotons")==0) {
373 +      FillerPhotons *fillerPhotons = new FillerPhotons(cfg, name.c_str(), defactive_);
374 +      addActiveFiller(fillerPhotons);
375 +      continue;
376 +    }  
377 +
378 +    if (ftype.compare("FillerStableParts")==0) {
379 +      FillerStableParts *fillerStableParts = new FillerStableParts(cfg, name.c_str(), defactive_);
380 +      addActiveFiller(fillerStableParts);
381 +      continue;
382 +    }  
383 +
384 +    if (ftype.compare("FillerDecayParts")==0) {
385 +      FillerDecayParts *fillerDecayParts = new FillerDecayParts(cfg, name.c_str(), defactive_);
386 +      addActiveFiller(fillerDecayParts);
387 +      continue;
388 +    }  
389 +    
390 +    if (ftype.compare("FillerPFCandidates")==0) {
391 +      FillerPFCandidates *fillerPFCands = new FillerPFCandidates(cfg, name.c_str(), defactive_);
392 +      addActiveFiller(fillerPFCands);
393 +      continue;
394 +    }  
395 +    if (ftype.compare("FillerPFJets")==0) {
396 +      FillerPFJets *fillerPFJets = new FillerPFJets(cfg, name.c_str(), defactive_);
397 +      addActiveFiller(fillerPFJets);
398 +      continue;
399 +    }  
400 +    if (ftype.compare("FillerJPTJets")==0) {
401 +      FillerJPTJets *fillerJPTJets = new FillerJPTJets(cfg, name.c_str(), defactive_);
402 +      addActiveFiller(fillerJPTJets);
403 +      continue;
404 +    }  
405 +
406 +    if (ftype.compare("FillerCaloTaus")==0) {
407 +      FillerCaloTaus *fillerCaloTaus = new FillerCaloTaus(cfg, name.c_str(), defactive_);
408 +      addActiveFiller(fillerCaloTaus);
409 +      continue;
410 +    }
411 +    
412 +    if (ftype.compare("FillerPFTaus")==0) {
413 +      FillerPFTaus *fillerPFTaus = new FillerPFTaus(cfg, name.c_str(), defactive_);
414 +      addActiveFiller(fillerPFTaus);
415 +      continue;
416 +    }  
417 +
418 +    if (ftype.compare("FillerTrackJets")==0) {
419 +      FillerTrackJets *fillerTrackJets = new FillerTrackJets(cfg, name.c_str(), defactive_);
420 +      addActiveFiller(fillerTrackJets);
421 +      continue;
422 +    }
423 +
424 +    if (ftype.compare("FillerEmbedWeight")==0) {
425 +      FillerEmbedWeight *fillerEmbedWeight = new FillerEmbedWeight(cfg, name.c_str(), defactive_);
426 +      addActiveFiller(fillerEmbedWeight);
427 +      continue;
428 +    }
429 +    
430 +    edm::LogError("FillMitTree")
431 +      << "Unknown fillerType " << ftype << " for pset named " << name << std::endl;
432 +    throw edm::Exception(edm::errors::Configuration, "FillMitTree::configure\n")
433 +      << "Unknown fillerType " << ftype << " for pset named " << name << std::endl;
434 +  }
435 +
436 +  return 1;
437 + }
438  
439 <  FillerMetaInfos *fillerMetaInfos = new FillerMetaInfos(cfg);
440 <  if (fillerMetaInfos->Active())
441 <    fillers_.push_back(fillerMetaInfos);
442 <  else
78 <    delete fillerMetaInfos;
79 <
80 <  FillerGlobalMuons *fillerGlobalMuons = new FillerGlobalMuons(cfg);
81 <  if (fillerGlobalMuons->Active())
82 <    fillers_.push_back(fillerGlobalMuons);
83 <  else
84 <    delete fillerGlobalMuons;
85 <
86 <  FillerGenParts *fillerGenParts = new FillerGenParts(cfg);
87 <  if (fillerGenParts->Active())
88 <    fillers_.push_back(fillerGenParts);
89 <  else
90 <    delete fillerGenParts;
439 > //--------------------------------------------------------------------------------------------------
440 > bool FillMitTree::configureTreeWriter(const edm::ParameterSet &cfg)
441 > {
442 >  // Configure tree writer with options from config file.
443  
444 +  tws_->SetPrefix(cfg.getUntrackedParameter<string>("fileName","mit-test"));
445 +  tws_->SetBaseURL(cfg.getUntrackedParameter<string>("pathName","."));
446 +  tws_->SetMaxSize((Long64_t)cfg.getUntrackedParameter<unsigned>("maxSize",1024)*1024*1024);
447 +  tws_->SetCompressLevel(cfg.getUntrackedParameter<unsigned>("compLevel",9));
448 +  tws_->SetDefaultSL(cfg.getUntrackedParameter<unsigned>("splitLevel",99));
449 +  tws_->SetDefaultBrSize(cfg.getUntrackedParameter<unsigned>("brSize",16*1024));
450 +  
451 +  if (OptInt::IsActivated()) {
452 +    OptInt::SetZipMode(cfg.getUntrackedParameter<unsigned>("zipMode",99));
453 +    OptInt::SetGzipFraction(cfg.getUntrackedParameter<double>("gZipThres",1.0));
454 +    OptInt::SetBzipFraction(cfg.getUntrackedParameter<double>("bZipThres",-1.0));
455 +    OptInt::SetLzoFraction(cfg.getUntrackedParameter<double>("lzoThres",-1.0));
456 +    OptInt::SetLzmaFraction(cfg.getUntrackedParameter<double>("lzmaThres",0.95));
457 +    OptInt::SetVerbose(cfg.getUntrackedParameter<unsigned>("optIOVerbose",0));
458 +
459 +  } else {
460 +
461 +    if (cfg.exists("zipMode")   || cfg.exists("bZipThres") ||
462 +        cfg.exists("gZipThres") || cfg.exists("lzoThres")  ||
463 +        cfg.exists("lzmaThres")) {
464 +      edm::LogError("FillMitTree") <<
465 +        "OptIO interface not properly pre-loaded, ignoring given settings." << std::endl;
466 +    }
467 +  }
468 +  
469    return 1;
470   }
471  
472 < //-------------------------------------------------------------------------------------------------
472 > //--------------------------------------------------------------------------------------------------
473   void FillMitTree::endJob()
474   {
475    // Delete fillers.
# Line 101 | Line 478 | void FillMitTree::endJob()
478      delete *iF;
479    }
480  
481 +  tws_->Clear();
482 +  
483    edm::LogInfo("FillMitTree::endJob") << "Ending Job" << endl;
484   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines