Public Methods | |
| ElectronObserver () | |
| ~ElectronObserver () | |
| void | upDate (G3EventProxy *ev) |
| ElectronObserver () | |
| void | upDate (G3SetUp *su) |
| ~ElectronObserver () | |
| void | upDate (G3EventProxy *ev) |
Public Attributes | |
| int | nbElectrons_ |
| SimpleConfigurable< bool > | produceReference_ |
| SimpleConfigurable< bool > | produceReference_ |
| SimpleConfigurable< string > | clusterizer_ |
| SimpleConfigurable< string > | bremsFinder_ |
| TrackReconstructor * | trackReconstructor_ |
| SimpleConfigurable< string > | trackReconstructorName_ |
| IsoCalculator * | ciso_ |
|
|
Definition at line 56 of file XANAElectronCandidate_level3selection.cpp. References nbElectrons_, and produceReference_.
00057 : nbElectrons_(0) 00058 { 00059 // initialize observer 00060 Observer<G3EventProxy *>::init() ; 00061 00062 // steering 00063 produceReference_=SimpleConfigurable<bool>(false,"XANAElectronCandidate:produceReference"); 00064 00065 } |
|
|
Definition at line 67 of file XANAElectronCandidate_level3selection.cpp. References nbElectrons_.
00068 {
00069 std::cout<<"[OVAL] number of electrons : "<<nbElectrons_<<endl ;
00070 }
|
|
|
Definition at line 102 of file XANAElectronCandidate_offline.cpp. References bremsFinder_, ciso_, clusterizer_, nbElectrons_, produceReference_, trackReconstructor_, and trackReconstructorName_.
00103 : nbElectrons_(0), trackReconstructor_(0) 00104 { 00105 // initialize observer 00106 Observer<G3EventProxy *>::init() ; 00107 Observer<G3SetUp *>::init() ; 00108 00109 // steering 00110 produceReference_=SimpleConfigurable<bool>(false,"XANAElectronCandidate:produceReference"); 00111 00112 // define electron algos by hand 00113 00114 // clusters 00115 clusterizer_=SimpleConfigurable<string>("EgammaBasicDynamic","XANAElectronCandidate:Clusterizer"); 00116 EgammaHAnalyzer<EgammaBasicCluster,EGDummy,CaloRecHit> *clustersUnit_=0; 00117 std::vector<const EgammaAlgorithm<EgammaBasicCluster,EGDummy,CaloRecHit> * > algos; 00118 if (clusterizer_.value()=="EgammaBasicDynamic") { 00119 clustersUnit_ = new EgammaHAnalyzer<EgammaBasicCluster,EGDummy,CaloRecHit>(new EgammaBasicDynamic) ; 00120 } else if (clusterizer_.value()=="EgammaBasicIsland") { 00121 clustersUnit_ = new EgammaHAnalyzer<EgammaBasicCluster,EGDummy,CaloRecHit>(new EgammaBasicIsland) ; 00122 } else if (clusterizer_.value()=="EgammaBasicHybrid") { 00123 clustersUnit_ = new EgammaHAnalyzer<EgammaBasicCluster,EGDummy,CaloRecHit>(new EgammaBasicHybrid) ; 00124 } else if (clusterizer_.value()=="EgammaDefault") { 00125 // from EgammaBasicClusters/src/EgammaBasicReco.cc 00126 vector<const EgammaAlgorithm<EgammaBasicCluster,EGDummy,CaloRecHit> * > algos; 00127 EgammaBasicIsland *island = new EgammaBasicIsland(); 00128 EgammaBasicHybrid *hybrid = new EgammaBasicHybrid(); 00129 algos.push_back(island); 00130 algos.push_back(hybrid); 00131 clustersUnit_ = new EgammaHAnalyzer<EgammaBasicCluster,EGDummy,CaloRecHit>(algos,0) ; 00132 // basic corrections 00133 clustersUnit_->SetCalib(new EgammaCalibrator<EgammaBasicCluster>(new EGBLogPosCorr(island))); 00134 clustersUnit_->AddCalib(new EgammaCalibrator<EgammaBasicCluster>(new EGBLogPosCorr(hybrid))); 00135 // activate isolation LazyObserver (island clusters only) 00136 IsoCalculator *isoc = Singleton<IsoCalculator>::instance(); 00137 isoc->SetRelevantAlgo(island); // necessary to tell IsoCalculator what 00138 // clusters to look for 00139 } else { 00140 throw Genexception("[ElectronObserver::ElectronObserver()], wrong cluster algo name") ; 00141 } 00142 clustersUnit_->changeName("EgammaBasicCluster") ; 00143 Reconstructor::addDefault(clustersUnit_) ; 00144 00145 // SUPERCLUSTERS 00146 // from EgammaSuperClusters/src/EgammaReco.cc 00147 EGSCSeedGenerator *seedgen = new EGSCSeedGenerator(); 00148 EgammaHAnalyzer<EgammaCluster, EGDummy, EgammaBasicCluster> *bd = 00149 new EgammaHAnalyzer<EgammaCluster, EGDummy, EgammaBasicCluster>(seedgen,0); 00150 00151 // SuperCluster and brem recovery 00152 bremsFinder_ = 00153 SimpleConfigurable<string>("EPBremRecovery","XANAElectronCandidate:BremsFinder"); 00154 EgammaHAnalyzer<EgammaSuperCluster,EgammaCluster,EgammaBasicCluster> *be = 0; 00155 std::cout << "bremsFinder_ " << bremsFinder_<< endl ; 00156 if (bremsFinder_.value()=="EPBremRecovery") { 00157 EPBremRecovery *brec = new EPBremRecovery(algos); 00158 be = new EgammaHAnalyzer<EgammaSuperCluster,EgammaCluster,EgammaBasicCluster>(brec,0); 00159 } else if (bremsFinder_.value()=="EgammaDefault") { 00160 EgammaBremRecovery *brec = new EgammaBremRecovery(); 00161 be = new EgammaHAnalyzer<EgammaSuperCluster,EgammaCluster,EgammaBasicCluster>(brec,0); 00162 } else 00163 throw Genexception("[XANAEsdBuilder::XANAEsdBuilder()], wrong brem recoverer algo name"); 00164 00165 // SuperCluster calibration using Chris's escale functions 00166 // Do we want this for EF super clusters? 00167 be->SetCalib(new EgammaCalibrator<EgammaSuperCluster>(new EgammaSCEnergyScale())); 00168 00169 // Endcap Preshower association/reconstruction 00170 EgammaEndcapAssociation *egea = new EgammaEndcapAssociation(); 00171 EgammaHAnalyzer<EgammaEndcapCluster,EgammaSuperCluster,CaloRecHit> *eea = 00172 new EgammaHAnalyzer<EgammaEndcapCluster,EgammaSuperCluster,CaloRecHit>(egea,0); 00173 00174 std::cout << "adding superclusters algos " << std::endl; 00175 Reconstructor::addDefault(bd); 00176 Reconstructor::addDefault(be); 00177 Reconstructor::addDefault(eea); 00178 00179 // define isolation algorithm as being the Egamma one 00180 ciso_ = Singleton<IsoCalculator>::instance(); 00181 00182 // initialisation of tracking algo must be done in observing G3SetUp 00183 trackReconstructorName_= 00184 SimpleConfigurable<string>("EPTracks","XANAElectronCandidate:TrackReconstructor"); 00185 00186 const MultipleScatteringUpdator aElectronMaterialEffectUpdator(0.000511); 00187 EFExtrapolatorToPoint * extrapolator = new EFExtrapolatorToPoint(new PropagatorWithMaterial(*(new AnalyticalPropagator(alongMomentum)),aElectronMaterialEffectUpdator)) ; 00188 00189 EFElectronFinder * electronsUnit_ = new EFElectronFinder() ; 00190 efLink(electronsUnit_,new EPSeededAssociator(BaseRecItr<EgammaSuperCluster>::defaultName(),trackReconstructorName_.value().c_str() )) ; 00191 efLink(electronsUnit_,new EFDummyDiscriminator) ; 00192 efLink(electronsUnit_,extrapolator) ; 00193 efLink(electronsUnit_,new EFBremsFinder(BaseRecItr<EgammaSuperCluster>::defaultName())) ; 00194 efLink(electronsUnit_,new EFBasicQualifier) ; 00195 efLink(electronsUnit_,new EFElectronPositionEstimator) ; 00196 efLink(electronsUnit_,new EFPositionCorrector) ; 00197 efLink(electronsUnit_,new EFBremsCorrector) ; 00198 efFreeze(electronsUnit_) ; 00199 Reconstructor::addDefault(electronsUnit_) ; 00200 00201 } |
|
|
Definition at line 222 of file XANAElectronCandidate_offline.cpp. References nbElectrons_.
00223 {
00224 std::cout<<"[OVAL] number of electrons : "<<nbElectrons_<<endl ;
00225 }
|
|
|
Definition at line 228 of file XANAElectronCandidate_offline.cpp. References nbElectrons_, XANAElectronCandidate::setAlgoName, and XANAElectronCandidate::setSuperCluster.
00229 {
00230
00231 if (!ev) return ;
00232
00233 // AutoRecCollection doesn't need explicit specification of event contrary to
00234 // RecItr, by using current event by default
00235 AutoRecCollection<EFElectron,G3EventProxy *> electrons ;
00236 AutoRecCollection<EFElectron,G3EventProxy *>::iterator electron ;
00237
00238 // to produce reference
00239 if (produceReference_) {
00240 // Electrons
00241 for (electron=electrons.begin(); electron!=electrons.end(); electron++)
00242 {
00243 nbElectrons_++ ;
00244 std::cout<<"[OVAL] new electron with e(seed)/p "<<(*electron)->getEnergyBalance()<<std::endl ;
00245 }
00246 return ;
00247 }
00248
00249 // construct XANAEmClusters from BasicClusters
00250 std::vector<XANAElectronCandidate> xelectrons;
00251 XANAElectronCandidate *xelectron;
00252 for (electron=electrons.begin(); electron!=electrons.end(); electron++)
00253 {
00254 nbElectrons_++ ;
00255 std::cout<<"constructing new XANAElectronCandidate .. "<<std::endl ;
00256 xelectron = new XANAElectronCandidate();
00257 // filling electron quantities
00258 xelectron->setAlgoName("ElectronFacilities");
00259 xelectron->setSuperCluster(0);
00260 xelectrons.push_back(*xelectron);
00261 }
00262
00263 // read XANAClusters
00264 std::vector<XANAElectronCandidate>::iterator it;
00265 for (it=xelectrons.begin(); it!=xelectrons.end(); it++)
00266 {
00267 // std::cout<<"[OVAL] new electron with e/p "<<(*it).getESuperClusterOverP()<<std::endl ;
00268 }
00269 }
|
|
|
Definition at line 207 of file XANAElectronCandidate_offline.cpp. References trackReconstructor_, and trackReconstructorName_.
00208 {
00209 // defines Tracking algo
00210 // beware! not to add to reconstructor! this is not a RecUnit
00211 // this will use default propagator, trajectory builder, etc..
00212 // seed algo
00213 EgammaAlgorithm<EPElectronSeed,EGDummy,EgammaSuperCluster> * seeds_algo
00214 = new EPForwardSeedGenerator ;
00215 EgammaHAnalyzer<EPElectronSeed,EGDummy,EgammaSuperCluster> * seeds_analyzer
00216 = new EgammaHAnalyzer<EPElectronSeed,EGDummy,EgammaSuperCluster>(seeds_algo) ;
00217 Reconstructor::addDefault(seeds_analyzer) ;
00218 trackReconstructor_
00219 = new TrackReconstructor(new EPSeededTrackReconstructor,trackReconstructorName_.value().c_str()) ;
00220 }
|
|
|
Definition at line 73 of file XANAElectronCandidate_level3selection.cpp. References nbElectrons_, XANAElectronCandidate::setAlgoName, XANAElectronCandidate::setCaloIsolation, XANAElectronCandidate::setESeedClusterOverP, XANAElectronCandidate::setESuperClusterOverP, XANAElectronCandidate::setHadronicOverEm, XANAElectronCandidate::setSuperClusterMomentum, and XANAElectronCandidate::setTrackIsolation.
00074 {
00075
00076 if (!ev) return ;
00077
00078 // AutoRecCollection doesn't need explicit specification of event contrary to
00079 // RecItr, by using current event by default
00080 AutoRecCollection<ElectronCandidate,G3EventProxy *> electrons ;
00081 AutoRecCollection<ElectronCandidate,G3EventProxy *>::iterator electron ;
00082
00083 // to produce reference
00084 if (produceReference_) {
00085 // Electrons
00086 for (electron=electrons.begin(); electron!=electrons.end(); electron++)
00087 {
00088 nbElectrons_++ ;
00089 std::cout<<"[OVAL] new electron with e/p "<<(*electron)->ele_EoP()<<std::endl ;
00090 }
00091 return ;
00092 }
00093
00094 // construct XANAEmClusters from BasicClusters
00095 std::vector<XANAElectronCandidate> xelectrons;
00096 XANAElectronCandidate *xelectron;
00097 for (electron=electrons.begin(); electron!=electrons.end(); electron++)
00098 {
00099 nbElectrons_++ ;
00100 // std::cout<<"[OVAL] new electron with e/p "<<(*electron)->ele_EoP()<<std::endl ;
00101 xelectron = new XANAElectronCandidate();
00102 // filling electron quantities
00103 // egamma electron has very limited interface in ORCA_7_4_0
00104 // so that many electron quantities cannot be filled in xanaelectron
00105 HepLorentzVector momentum;
00106 // unfilled, needs acces to electron track parameters
00107 // momentum=(*electron)->getElectronPTK();
00108 // momentum *= (*electron)->SCE() / (*electron)->getElectronPTK().e();
00109 xelectron->setMomentum(momentum);
00110 xelectron->setPt(momentum.perp());
00111 HepLorentzVector superClusterMomentum;
00112 // unfilled, needs acces to electron supercluster
00113 // superClusterMomentum=(*electron)->getElectronPSC();
00114 xelectron->setSuperClusterMomentum(superClusterMomentum);
00115 HepLorentzVector trackMomentumAtImpact;
00116 // unfilled, needs acces to electron track Pt and supercluster energy
00117 // trackMomentumAtImpact=(*electron)->getElectronPTK();
00118 xelectron->setTrackMomentumAtImpact(trackMomentumAtImpact);
00119 HepLorentzVector superClusterMomentumUsingTrack;
00120 xelectron->setSuperClusterMomentumUsingTrack(superClusterMomentumUsingTrack);
00121 HepPoint3D positionAtCalo;
00122 float theta = 2.*atan(exp(-(*electron)->SCEta()));
00123 // unfilled, needs acces to super cluster radius
00124 // float x = (*electron)->Radius()*sin(theta)*cos((*electron)->Phi());
00125 // float y = (*electron)->Radius()*sin(theta)*sin((*electron)->Phi());
00126 // float z = (*electron)->Radius()*cos(theta);
00127 xelectron->setPositionAtCalo(positionAtCalo);
00128 float eSuperClusterOverP = (*electron)->ele_EoP();
00129 xelectron->setESuperClusterOverP(eSuperClusterOverP);
00130 // unfilled, needs access to electron seed cluster
00131 float eSeedClusterOverP;
00132 xelectron->setESeedClusterOverP(eSeedClusterOverP);
00133 float deltaEtaSuperCluster = (*electron)->DeltaEta();
00134 xelectron->setDeltaEtaSuperCluster(deltaEtaSuperCluster);
00135 // unfilled, needs access to electron seed cluster
00136 float deltaEtaSeedCluster;
00137 xelectron->setDeltaEtaSeedCluster(deltaEtaSeedCluster);
00138 // unfilled, no delta phi in ElectronCandidate interface!
00139 float deltaPhiSuperCluster;
00140 xelectron->setDeltaPhiSuperCluster(deltaPhiSuperCluster);
00141 // unfilled, needs access to seed cluster
00142 float deltaPhiSeedCluster;
00143 xelectron->setDeltaPhiSeedCluster(deltaPhiSeedCluster);
00144 // ElectronCandidate interface only providing boolean
00145 // int isTrackIsolated = (*electron)->TRisISO();
00146 float trackIsolation;
00147 xelectron->setTrackIsolation(trackIsolation);
00148 // unfilled, needs access to supercluster isolation
00149 float caloIsolation;
00150 xelectron->setCaloIsolation(caloIsolation);
00151 float hadronicOverEm = (*electron)->ele_HoE();
00152 xelectron->setHadronicOverEm(hadronicOverEm);
00153 xelectron->setAlgoName("EgammaCandidate");
00154 // xelectron->setSuperCluster(0);
00155 xelectrons.push_back(*xelectron);
00156 }
00157
00158 // read XANAElectrons
00159 std::vector<XANAElectronCandidate>::iterator it;
00160 for (it=xelectrons.begin(); it!=xelectrons.end(); it++)
00161 {
00162 std::cout<<"[OVAL] new electron with e/p "<<(*it).getESuperClusterOverP()<<std::endl ;
00163 }
00164 }
|
|
|
Definition at line 97 of file XANAElectronCandidate_offline.cpp. Referenced by ElectronObserver. |
|
|
Definition at line 100 of file XANAElectronCandidate_offline.cpp. Referenced by ElectronObserver. |
|
|
Definition at line 96 of file XANAElectronCandidate_offline.cpp. Referenced by ElectronObserver. |
|
|
Definition at line 94 of file XANAElectronCandidate_offline.cpp. Referenced by ElectronObserver, upDate, and ~ElectronObserver. |
|
|
Definition at line 95 of file XANAElectronCandidate_offline.cpp. |
|
|
Definition at line 54 of file XANAElectronCandidate_level3selection.cpp. Referenced by ElectronObserver. |
|
|
Definition at line 98 of file XANAElectronCandidate_offline.cpp. Referenced by ElectronObserver, and upDate. |
|
|
Definition at line 99 of file XANAElectronCandidate_offline.cpp. Referenced by ElectronObserver, and upDate. |
1.2.14 written by Dimitri van Heesch,
© 1997-2002