15 desc.
add<
bool>(
"ignoreVertices",
false);
17 std::vector<double>
cuts = {-.7, 0.1, .7};
18 desc.
add<std::vector<double>>(
"qualityCuts",
cuts);
30 auto const & qv = cfg.
getParameter<std::vector<double>>(
"qualityCuts");
34 produces<MVACollection>(
"MVAValues");
35 produces<QualityMaskCollection>(
"QualityMasks");
44 auto const &
tracks(*hSrcTrack);
57 auto mvas = std::make_unique<MVACollection>(
tracks.size(),-99.f);
58 auto quals = std::make_unique<QualityMaskCollection>(
tracks.size(),0);
64 edm::LogWarning(
"TrackMVAClassifierBase") <<
"ignoreVertices is set to False in the configuration, but the vertex collection is not valid";
68 assert((*mvas).size()==
tracks.size());
T getParameter(std::string const &) const
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
TrackMVAClassifierBase(const edm::ParameterSet &cfg)
virtual void initEvent(const edm::EventSetup &es)=0
bool getByToken(EDGetToken token, Handle< PROD > &result) const
edm::EDGetTokenT< reco::TrackCollection > src_
source collection label
std::vector< Track > TrackCollection
collection of Tracks
static void fill(edm::ParameterSetDescription &desc)
std::vector< Vertex > VertexCollection
collection of Vertex objects
~TrackMVAClassifierBase() override
virtual void computeMVA(reco::TrackCollection const &tracks, reco::BeamSpot const &beamSpot, reco::VertexCollection const &vertices, MVACollection &mvas) const =0
edm::EDGetTokenT< reco::BeamSpot > beamspot_
void produce(edm::Event &evt, const edm::EventSetup &es) final
edm::EDGetTokenT< reco::VertexCollection > vertices_
ParameterDescriptionBase * add(U const &iLabel, T const &value)