7 #include "CLHEP/Units/SystemOfUnits.h"
13 #include "CaloEvent/CaloClusterContainer.h"
28 declareInterface<IDataRetriever>(
this);
31 "Collection to be first in output, shown in Atlantis without switching");
48 if (
sc.isFailure() ) {
67 (
iterator.key() !=
"CaloESDMuonCollection" )) {
80 return StatusCode::SUCCESS;
106 DataVect etConeIsol; etConeIsol.reserve(muoncont->
size());
110 DataVect clusterKeyVec; clusterKeyVec.reserve(muoncont->
size());
111 DataVect clusterIndexVec; clusterIndexVec.reserve(muoncont->
size());
112 DataVect trackKeyVec; trackKeyVec.reserve(muoncont->
size());
113 DataVect trackIndexVec; trackIndexVec.reserve(muoncont->
size());
119 std::string clusterKey =
"none";
120 int clusterIndex = -1;
121 std::string trackKey =
"none";
124 for (; muonItr != muonItrE; ++muonItr) {
125 phi.emplace_back((*muonItr)->phi());
126 eta.emplace_back((*muonItr)->eta());
134 pdgId.emplace_back( (*muonItr)->pdgId() );
136 std::string muonAuthor =
"none";
137 if (( (*muonItr)->author()) == 0){ muonAuthor =
"unknown"; }
138 if (( (*muonItr)->author()) == 1){ muonAuthor =
"highpt"; }
139 if (( (*muonItr)->author()) == 2){ muonAuthor =
"lowpt"; }
140 author.emplace_back( muonAuthor );
142 MCdataType = (*muonItr)->dataType();
143 dataType.emplace_back( MCdataType );
148 if (MCdataType != 3){
149 chi2.emplace_back( (*muonItr)->matchChi2OverDoF() );
150 etConeIsol.emplace_back(
157 " Muon: matchChi2OverDoF: " << (*muonItr)->matchChi2OverDoF() <<
158 ", matchChi2: " << (*muonItr)->matchChi2() <<
159 ", fitChi2: " << (*muonItr)->fitChi2() <<
160 ", isCombined: " << (
int)(*muonItr)->isCombinedMuon() );
169 trackKey = trackLink.
dataID();
170 trackIndex = trackLink.
index();
171 trackKeyVec.emplace_back( trackKey );
172 trackIndexVec.emplace_back( trackIndex );
174 trackKeyVec.emplace_back(
"none" );
175 trackIndexVec.emplace_back( -1 );
179 clusterKey = clusterLink.
dataID();
180 clusterIndex = clusterLink.
index();
181 clusterKeyVec.emplace_back( clusterKey );
182 clusterIndexVec.emplace_back( clusterIndex );
184 clusterKeyVec.emplace_back(
"none" );
185 clusterIndexVec.emplace_back( -1 );
189 chi2.emplace_back( 0 );
190 etConeIsol.emplace_back( 0 );
191 trackKeyVec.emplace_back(
"none" );
192 trackIndexVec.emplace_back( -1 );
193 clusterKeyVec.emplace_back(
"none");
194 clusterIndexVec.emplace_back( -1 );
199 DataMap[
"phi"] = std::move(phi);
200 DataMap[
"eta"] = std::move(eta);
210 DataMap[
"etConeIsol"] = std::move(etConeIsol);
212 DataMap[
"pdgId"] = std::move(pdgId);
215 DataMap[
"clusterKey"] = std::move(clusterKeyVec);
216 DataMap[
"clusterIndex"] = std::move(clusterIndexVec);
217 DataMap[
"trackKey"] = std::move(trackKeyVec);
218 DataMap[
"trackIndex"] = std::move(trackIndexVec);