63 if (!pBarrelSuperClusters.
isValid()){
74 if (!pEndcapSuperClusters.
isValid()){
83 bool meet_single_thresh =
false;
85 for (
int loop=0;
loop<int(BarrelSuperClusters.size());
loop++){
87 float eta1 = clus1.
eta();
88 float energy1 = clus1.
energy();
89 float theta1 = 2*atan(
exp(-1.*eta1));
90 float cluspt1 = energy1 *
sin(theta1);
92 saveBarrelSuperClusters.push_back(clus1);
94 meet_single_thresh =
true;
100 for (
int loop=0;
loop<int(EndcapSuperClusters.size());
loop++){
102 float eta1 = clus1.
eta();
103 float energy1 = clus1.
energy();
104 float theta1 = 2*atan(
exp(-1.*eta1));
105 float cluspt1 = energy1 *
sin(theta1);
107 saveEndcapSuperClusters.push_back(clus1);
109 meet_single_thresh =
true;
115 int TotClus = saveBarrelSuperClusters.size() + saveEndcapSuperClusters.size();
119 if (TotClus >=
nclus_sel_ || meet_single_thresh){
121 if (saveBarrelSuperClusters.size() > 0){
140 std::vector<DetId> saveTheseDetIds;
142 for (
int loop = 0;
loop < int(saveBarrelSuperClusters.size());
loop++){
147 std::pair<DetId, float> EDetty = tooly.getMaximum(*bc);
149 std::vector<DetId> detvec = tooly.matrixDetId(EDetty.first, -1, 1, -1, 1);
151 for (
int ik = 0;ik<int(detvec.size());++ik)
152 saveTheseDetIds.push_back(detvec[ik]);
155 for (
int detloop=0; detloop < int(saveTheseDetIds.size());++detloop){
159 blah!=digis->
end();blah++){
161 if (detL == blah->id()){
163 SEBDigiCol->push_back(detL);
166 for (
int iq =0;iq<myDigi.
size();++iq){
183 if (saveEndcapSuperClusters.size() > 0){
197 std::set<DetId> saveTheseDetIds;
199 for (
int loop = 0;
loop < int(saveEndcapSuperClusters.size());
loop++){
204 std::pair<DetId, float> EDetty = tooly.getMaximum(*bc);
206 std::vector<DetId> detvec = tooly.matrixDetId(EDetty.first, -1, 1, -1, 1);
208 for (
int ik = 0;ik<int(detvec.size());++ik)
210 saveTheseDetIds.insert(detvec[ik]);
214 blah!=digis->
end();blah++){
215 std::set<DetId>::const_iterator finder = saveTheseDetIds.find(blah->id());
216 if (finder!=saveTheseDetIds.end()){
219 if (detL == blah->id()){
221 SEEDigiCol->push_back(detL);
223 for (
int iq =0;iq<myDigi.
size();++iq){
230 if (eecounter >=
int(saveTheseDetIds.size()))
break;
boost::transform_iterator< IterHelp, boost::counting_iterator< int > > const_iterator
edm::InputTag barrelSuperClusterProducer_
Sin< T >::type sin(const T &t)
EcalMGPASample sample(int i) const
const_iterator begin() const
uint16_t raw() const
get the raw word
double eta() const
pseudorapidity of cluster centroid
std::string selectedEcalEEDigiCollection_
std::string selectedEcalEBDigiCollection_
edm::InputTag EcalEEDigiTag_
T const * get() const
Returns C++ pointer to the item.
std::vector< SuperCluster > SuperClusterCollection
collection of SuperCluser objectr
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
edm::InputTag endcapSuperClusterProducer_
edm::InputTag EcalEERecHitTag_
double cluster_pt_thresh_
double energy() const
cluster energy
edm::InputTag EcalEBRecHitTag_
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
T const * product() const
const_iterator end() const
void setSample(int i, EcalMGPASample sam)
edm::InputTag EcalEBDigiTag_
const CaloClusterPtr & seed() const
seed BasicCluster
double single_cluster_thresh_