6 : sessionRef_(
cache->session) {
26 if (
fPt_.get()[i0] == 0) {
27 for (
int i1 = 0;
i1 < 13;
i1++)
51 std::vector<tensorflow::Tensor>
outputs;
53 return outputs[0].matrix<
float>()(0, 0);
69 return (
i->pt() >
j->pt());
71 float jetpt = useRawPt ? iJet.
rawPt() : iJet.
pt();
72 for (
unsigned int i0 = 0; i0 < iParts.size(); i0++) {
75 fPt_.get()[i0] = iParts[i0]->pt() / jetpt;
76 fEta_.get()[i0] = iParts[i0]->eta() - iJet.
eta();
78 fId_.get()[i0] = iParts[i0]->id();
79 fCharge_.get()[i0] = iParts[i0]->charge();
80 if (iParts[i0]->
pfTrack().isNonnull()) {
81 fDX_.get()[i0] = iParts[i0]->pfTrack()->vx();
82 fDY_.get()[i0] = iParts[i0]->pfTrack()->vy();
83 fDZ_.get()[i0] = iParts[i0]->pfTrack()->vz() - vz;
float compute(const l1t::PFJet &iJet, float vz, bool useRawPt)
double pt() const final
transverse momentum
tensorflow::Session * sessionRef_
unique_ptr< float[]> fPhi_
unique_ptr< int[]> fCharge_
unique_ptr< float[]> fId_
static std::string const input
unique_ptr< float[]> fDX_
void run(Session *session, const NamedTensorList &inputs, const std::vector< std::string > &outputNames, std::vector< Tensor > *outputs, const thread::ThreadPoolOptions &threadPoolOptions)
unique_ptr< float[]> fDZ_
const Constituents & constituents() const
constituent information. note that this is not going to be available in the hardware! ...
BJetId(const std::string &iInput, const std::string &iOutput, const BJetTFCache *cache, int iNParticles)
unique_ptr< float[]> fDY_
unique_ptr< float[]> fEta_
unique_ptr< float[]> fPt_
std::vector< float > NNvectorVar_
double phi() const final
momentum azimuthal angle
double eta() const final
momentum pseudorapidity