ATLAS Offline Software
Loading...
Searching...
No Matches
TrigInDetUtils.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TRIGINDETPATTRECOTOOLS_TRIG_INDET_UTILS_H
6#define TRIGINDETPATTRECOTOOLS_TRIG_INDET_UTILS_H
7
8#include "TrkTrack/Track.h"
9#include <vector>
10
12
13struct trackInfo {
14 int n_hits_pix = 0; int n_hits_sct = 0; int n_hits_inner = 0; int n_hits_innermost = 0;
15 float ptGeV = 0; float a0beam = 0;float eta = 0; float phi0 = 0;
16};
17
18namespace FTF {
19 bool isGoodTrackUTT(const Trk::Track* track, trackInfo& theTrackInfo, const float shift_x, const float shift_y, float trkcut_ptgev);
20 void getBeamSpotShift(float& shift_x, float& shift_y, const InDet::BeamSpotData& beamSpotHandle);
21}
22
23typedef struct WeightedCoordinate{
24 struct Comparator {
25 bool operator()(const struct WeightedCoordinate& wc1, const struct WeightedCoordinate& wc2) {
26 return (wc2.m_x > wc1.m_x);
27 }
28 };
29public:
30WeightedCoordinate(double x, double w) : m_x(x), m_w(w) {};
32 double m_x, m_w;
33private:
34WeightedCoordinate() : m_x(0.0), m_w(0.0) {};
36
37typedef class CdfApproximator {
38 public:
40 double findMedian(std::vector<WEIGHTED_COORDINATE>&);
41 double findModes(std::vector<WEIGHTED_COORDINATE>&, std::vector<double>&, int);
43
44#endif
struct WeightedCoordinate WEIGHTED_COORDINATE
class CdfApproximator CDF_APPROXIMATOR
#define x
double findMedian(std::vector< WEIGHTED_COORDINATE > &)
double findModes(std::vector< WEIGHTED_COORDINATE > &, std::vector< double > &, int)
header for factorised IRoiDescriptor interface
void getBeamSpotShift(float &shift_x, float &shift_y, const InDet::BeamSpotData &beamSpotHandle)
bool isGoodTrackUTT(const Trk::Track *track, trackInfo &theTrackInfo, const float shift_x, const float shift_y, float trkcut_ptgev)
bool operator()(const struct WeightedCoordinate &wc1, const struct WeightedCoordinate &wc2)
WeightedCoordinate(const WeightedCoordinate &wc)
WeightedCoordinate(double x, double w)
int n_hits_innermost