VLNEnergyProducer_module.cc
Go to the documentation of this file.
3 
6 
7 namespace VLN {
8 
10 {
11 public:
12  explicit VLNEnergyProducer(const fhicl::ParameterSet &pset);
13  void produce(art::Event &evt) override;
14 
15 private:
19 };
20 
22  : EDProducer(pset),
23  inputVarExtractor("", pset.get<fhicl::ParameterSet>("ConfigInputVars")),
24  model(pset.get<std::string>("ModelPath"))
25 {
26  produces<VLNEnergy>();
27 }
28 
30 {
32  VLNEnergy energy = model.predict(vars);
33 
34  evt.put(std::make_unique<VLNEnergy>(std::move(energy)));
35 }
36 
38 
39 }
40 
std::string string
Definition: nybbler.cc:12
EDProducer(fhicl::ParameterSet const &pset)
Definition: EDProducer.h:20
STL namespace.
Definition: model.py:1
Definition: VarDict.h:8
virtual void extract(const art::Event &evt, VarDict &vars)
#define DEFINE_ART_MODULE(klass)
Definition: ModuleMacros.h:67
def move(depos, offset)
Definition: depos.py:107
Definition: utils.cxx:6
ProductID put(std::unique_ptr< PROD > &&edp, std::string const &instance={})
Definition: DataViewImpl.h:686
VLNEnergyProducer(const fhicl::ParameterSet &pset)
TCEvent evt
Definition: DataStructs.cxx:7
auto const & get(AssnsNode< L, R, D > const &r)
Definition: AssnsNode.h:115
void produce(art::Event &evt) override
DefaultInputVarExtractor inputVarExtractor