File indexing completed on 2024-04-06 12:24:25
0001 #ifndef RecoBTag_FeatureTools_SeedingTracksConverter_h
0002 #define RecoBTag_FeatureTools_SeedingTracksConverter_h
0003
0004 #include "DataFormats/PatCandidates/interface/PackedCandidate.h"
0005 #include "DataFormats/ParticleFlowCandidate/interface/PFCandidate.h"
0006
0007 #include "DataFormats/BTauReco/interface/SeedingTrackFeatures.h"
0008 #include "DataFormats/BTauReco/interface/TrackPairFeatures.h"
0009
0010 #include "RecoBTag/FeatureTools/interface/TrackPairInfoBuilder.h"
0011 #include "RecoBTag/FeatureTools/interface/SeedingTrackInfoBuilder.h"
0012
0013 #include "DataFormats/PatCandidates/interface/Jet.h"
0014
0015 #include "TrackingTools/TransientTrack/interface/TransientTrackBuilder.h"
0016 #include "TrackingTools/IPTools/interface/IPTools.h"
0017 #include "TrackingTools/Records/interface/TransientTrackRecord.h"
0018 #include "RecoVertex/VertexTools/interface/VertexDistance3D.h"
0019
0020 #include "RecoBTag/TrackProbability/interface/HistogramProbabilityEstimator.h"
0021
0022 namespace btagbtvdeep {
0023
0024 void seedingTracksToFeatures(const std::vector<reco::TransientTrack>& selectedTracks,
0025 const std::vector<float>& masses,
0026 const reco::Jet& jet,
0027 const reco::Vertex& pv,
0028 HistogramProbabilityEstimator* probabilityEstimator,
0029 bool computeProbabilities,
0030 std::vector<btagbtvdeep::SeedingTrackFeatures>& seedingT_features_vector);
0031
0032 inline float logWithOffset(float v, float logOffset = 0) {
0033 if (v == 0.)
0034 return 0.;
0035 return logOffset + log(std::fabs(v)) * std::copysign(1.f, v);
0036 };
0037 }
0038
0039 #endif