CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Private Attributes
TrackSoAHeterogeneousT< S > Class Template Reference

#include <TrackSoAHeterogeneousT.h>

Public Types

using hindex_type = uint32_t
 
using HitContainer = cms::cuda::OneToManyAssoc< hindex_type, S+1, 5 *S >
 
using Quality = pixelTrack::Quality
 

Public Member Functions

constexpr float charge (int32_t i) const
 
constexpr int computeNumberOfLayers (int32_t i) const
 
constexpr bool isTriplet (int i) const
 
constexpr int nHits (int i) const
 
constexpr int nTracks () const
 
constexpr float phi (int32_t i) const
 
constexpr Quality quality (int32_t i) const
 
constexpr Qualityquality (int32_t i)
 
constexpr Quality const * qualityData () const
 
constexpr QualityqualityData ()
 
constexpr void setNTracks (int n)
 
constexpr float tip (int32_t i) const
 
constexpr float zip (int32_t i) const
 

Static Public Member Functions

static constexpr int32_t stride ()
 

Public Attributes

eigenSoA::ScalarSoA< float, Schi2
 
HitContainer detIndices
 
eigenSoA::ScalarSoA< float, Seta
 
HitContainer hitIndices
 
eigenSoA::ScalarSoA< int8_t, SnLayers
 
eigenSoA::ScalarSoA< float, Spt
 
TrajectoryStateSoAT< SstateAtBS
 

Private Attributes

int nTracks_
 
eigenSoA::ScalarSoA< uint8_t, Squality_
 

Detailed Description

template<int32_t S>
class TrackSoAHeterogeneousT< S >

Definition at line 24 of file TrackSoAHeterogeneousT.h.

Member Typedef Documentation

◆ hindex_type

template<int32_t S>
using TrackSoAHeterogeneousT< S >::hindex_type = uint32_t

Definition at line 29 of file TrackSoAHeterogeneousT.h.

◆ HitContainer

template<int32_t S>
using TrackSoAHeterogeneousT< S >::HitContainer = cms::cuda::OneToManyAssoc<hindex_type, S + 1, 5 * S>

Definition at line 30 of file TrackSoAHeterogeneousT.h.

◆ Quality

template<int32_t S>
using TrackSoAHeterogeneousT< S >::Quality = pixelTrack::Quality

Definition at line 28 of file TrackSoAHeterogeneousT.h.

Member Function Documentation

◆ charge()

template<int32_t S>
constexpr float TrackSoAHeterogeneousT< S >::charge ( int32_t  i) const
inline

Definition at line 74 of file TrackSoAHeterogeneousT.h.

References f, mps_fire::i, and TrackSoAHeterogeneousT< S >::stateAtBS.

Referenced by L2TauNNProducer::fillPatatracks().

74 { return std::copysign(1.f, stateAtBS.state(i)(2)); }
TrajectoryStateSoAT< S > stateAtBS
double f[11][100]

◆ computeNumberOfLayers()

template<int32_t S>
constexpr int TrackSoAHeterogeneousT< S >::computeNumberOfLayers ( int32_t  i) const
inline

Definition at line 55 of file TrackSoAHeterogeneousT.h.

References TrackSoAHeterogeneousT< S >::detIndices, phase1PixelTopology::getLayer(), and mps_fire::i.

55  {
56  // layers are in order and we assume tracks are either forward or backward
57  auto pdet = detIndices.begin(i);
58  int nl = 1;
59  auto ol = phase1PixelTopology::getLayer(*pdet);
60  for (; pdet < detIndices.end(i); ++pdet) {
61  auto il = phase1PixelTopology::getLayer(*pdet);
62  if (il != ol)
63  ++nl;
64  ol = il;
65  }
66  return nl;
67  }
constexpr uint8_t getLayer(uint32_t detId)

◆ isTriplet()

template<int32_t S>
constexpr bool TrackSoAHeterogeneousT< S >::isTriplet ( int  i) const
inline

Definition at line 53 of file TrackSoAHeterogeneousT.h.

References mps_fire::i, and TrackSoAHeterogeneousT< S >::nLayers.

53 { return nLayers(i) == 3; }
eigenSoA::ScalarSoA< int8_t, S > nLayers

◆ nHits()

template<int32_t S>
constexpr int TrackSoAHeterogeneousT< S >::nHits ( int  i) const
inline

◆ nTracks()

template<int32_t S>
constexpr int TrackSoAHeterogeneousT< S >::nTracks ( ) const
inline

◆ phi()

template<int32_t S>
constexpr float TrackSoAHeterogeneousT< S >::phi ( int32_t  i) const
inline

◆ quality() [1/2]

template<int32_t S>
constexpr Quality TrackSoAHeterogeneousT< S >::quality ( int32_t  i) const
inline

Definition at line 38 of file TrackSoAHeterogeneousT.h.

References mps_fire::i, and TrackSoAHeterogeneousT< S >::quality_.

38 { return (Quality)(quality_(i)); }
eigenSoA::ScalarSoA< uint8_t, S > quality_

◆ quality() [2/2]

template<int32_t S>
constexpr Quality& TrackSoAHeterogeneousT< S >::quality ( int32_t  i)
inline

Definition at line 39 of file TrackSoAHeterogeneousT.h.

References mps_fire::i, and TrackSoAHeterogeneousT< S >::quality_.

39 { return (Quality &)(quality_(i)); }
eigenSoA::ScalarSoA< uint8_t, S > quality_

◆ qualityData() [1/2]

template<int32_t S>
constexpr Quality const* TrackSoAHeterogeneousT< S >::qualityData ( ) const
inline

◆ qualityData() [2/2]

template<int32_t S>
constexpr Quality* TrackSoAHeterogeneousT< S >::qualityData ( )
inline

Definition at line 41 of file TrackSoAHeterogeneousT.h.

References eigenSoA::ScalarSoA< T, S >::data(), and TrackSoAHeterogeneousT< S >::quality_.

41 { return (Quality *)(quality_.data()); }
eigenSoA::ScalarSoA< uint8_t, S > quality_
__host__ __device__ constexpr Scalar * data()
Definition: eigenSoA.h:26

◆ setNTracks()

template<int32_t S>
constexpr void TrackSoAHeterogeneousT< S >::setNTracks ( int  n)
inline

◆ stride()

template<int32_t S>
static constexpr int32_t TrackSoAHeterogeneousT< S >::stride ( )
inlinestatic

◆ tip()

template<int32_t S>
constexpr float TrackSoAHeterogeneousT< S >::tip ( int32_t  i) const
inline

Definition at line 76 of file TrackSoAHeterogeneousT.h.

References mps_fire::i, and TrackSoAHeterogeneousT< S >::stateAtBS.

76 { return stateAtBS.state(i)(1); }
TrajectoryStateSoAT< S > stateAtBS

◆ zip()

template<int32_t S>
constexpr float TrackSoAHeterogeneousT< S >::zip ( int32_t  i) const
inline

Definition at line 77 of file TrackSoAHeterogeneousT.h.

References mps_fire::i, and TrackSoAHeterogeneousT< S >::stateAtBS.

77 { return stateAtBS.state(i)(4); }
TrajectoryStateSoAT< S > stateAtBS

Member Data Documentation

◆ chi2

template<int32_t S>
eigenSoA::ScalarSoA<float, S> TrackSoAHeterogeneousT< S >::chi2

◆ detIndices

template<int32_t S>
HitContainer TrackSoAHeterogeneousT< S >::detIndices

◆ eta

template<int32_t S>
eigenSoA::ScalarSoA<float, S> TrackSoAHeterogeneousT< S >::eta

◆ hitIndices

template<int32_t S>
HitContainer TrackSoAHeterogeneousT< S >::hitIndices

◆ nLayers

template<int32_t S>
eigenSoA::ScalarSoA<int8_t, S> TrackSoAHeterogeneousT< S >::nLayers

Definition at line 46 of file TrackSoAHeterogeneousT.h.

Referenced by TrackSoAHeterogeneousT< S >::isTriplet().

◆ nTracks_

template<int32_t S>
int TrackSoAHeterogeneousT< S >::nTracks_
private

◆ pt

template<int32_t S>
eigenSoA::ScalarSoA<float, S> TrackSoAHeterogeneousT< S >::pt

◆ quality_

template<int32_t S>
eigenSoA::ScalarSoA<uint8_t, S> TrackSoAHeterogeneousT< S >::quality_
private

◆ stateAtBS

template<int32_t S>
TrajectoryStateSoAT<S> TrackSoAHeterogeneousT< S >::stateAtBS