CMS 3D CMS Logo

Functions
PFDisplacedVertexCandidateFinder.cc File Reference
#include <memory>
#include "RecoParticleFlow/PFTracking/interface/PFDisplacedVertexCandidateFinder.h"
#include "DataFormats/GeometryVector/interface/GlobalVector.h"
#include "DataFormats/TrackReco/interface/Track.h"
#include "DataFormats/VertexReco/interface/Vertex.h"
#include "MagneticField/Engine/interface/MagneticField.h"

Go to the source code of this file.

Functions

ostream & operator<< (std::ostream &out, const PFDisplacedVertexCandidateFinder &a)
 

Function Documentation

◆ operator<<()

ostream& operator<< ( std::ostream &  out,
const PFDisplacedVertexCandidateFinder a 
)

Definition at line 332 of file PFDisplacedVertexCandidateFinder.cc.

332  {
333  if (!out)
334  return out;
335 
336  out << "====== Particle Flow Block Algorithm ======= ";
337  out << endl;
338  out << "number of unassociated elements : " << a.eventTracks_.size() << endl;
339  out << endl;
340 
341  out << " Tracks selection based on " << std::endl;
342  out << " pvtx_ = " << a.pvtx_ << std::endl;
343  out << " std::abs(dxy) < " << a.dxy_ << " and pt < " << a.pt_min_prim_ << std::endl;
344  out << " nChi2 < " << a.nChi2_max_ << " and pt < " << a.pt_min_ << std::endl;
345 
346  out << endl;
347 
348  for (PFDisplacedVertexCandidateFinder::IEC ie = a.eventTracks_.begin(); ie != a.eventTracks_.end(); ie++) {
349  double pt = (*ie).get()->pt();
350 
351  math::XYZPoint Pi = (*ie).get()->innerPosition();
352  math::XYZPoint Po = (*ie).get()->outerPosition();
353 
354  double innermost_radius = sqrt(Pi.x() * Pi.x() + Pi.y() * Pi.y() + Pi.z() * Pi.z());
355  double outermost_radius = sqrt(Po.x() * Po.x() + Po.y() * Po.y() + Po.z() * Po.z());
356  double innermost_rho = sqrt(Pi.x() * Pi.x() + Pi.y() * Pi.y());
357  double outermost_rho = sqrt(Po.x() * Po.x() + Po.y() * Po.y());
358 
359  out << "ie = " << (*ie).key() << " pt = " << pt << " innermost hit radius = " << innermost_radius
360  << " rho = " << innermost_rho << " outermost hit radius = " << outermost_radius << " rho = " << outermost_rho
361  << endl;
362  }
363 
364  const std::unique_ptr<reco::PFDisplacedVertexCandidateCollection>& vertexCandidates = std::move(a.vertexCandidates());
365 
366  if (!vertexCandidates.get()) {
367  out << "vertexCandidates already transfered" << endl;
368  } else {
369  out << "number of vertexCandidates : " << vertexCandidates->size() << endl;
370  out << endl;
371 
372  for (PFDisplacedVertexCandidateFinder::IBC ib = vertexCandidates->begin(); ib != vertexCandidates->end(); ib++)
373  ib->Dump();
374  }
375 
376  return out;
377 }

References a, cuy::ib, eostools::move(), MillePedeFileConverter_cfg::out, Pi, DiDispStaMuonMonitor_cfi::pt, mathSSE::sqrt(), and PFDisplacedVertexCandidateFinder::vertexCandidates().

DiDispStaMuonMonitor_cfi.pt
pt
Definition: DiDispStaMuonMonitor_cfi.py:39
mathSSE::sqrt
T sqrt(T t)
Definition: SSEVec.h:19
math::XYZPoint
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:12
a
double a
Definition: hdecay.h:119
cuy.ib
ib
Definition: cuy.py:662
PFDisplacedVertexCandidateFinder::IBC
reco::PFDisplacedVertexCandidateCollection::const_iterator IBC
Definition: PFDisplacedVertexCandidateFinder.h:37
eostools.move
def move(src, dest)
Definition: eostools.py:511
PFDisplacedVertexCandidateFinder::IEC
std::list< reco::TrackBaseRef >::const_iterator IEC
Definition: PFDisplacedVertexCandidateFinder.h:36
Pi
const double Pi
Definition: CosmicMuonParameters.h:18
MillePedeFileConverter_cfg.out
out
Definition: MillePedeFileConverter_cfg.py:31