8 #ifndef SensorGridPhotodetector_HH
9 #define SensorGridPhotodetector_HH
25 double const & pde_init,
double const & noise_rate_init,
double const & time_res_init);
30 void Init(
SensorGridBase* sensor_grid_,
bool per_pixel_traits_,
double const & efficiency_init,
double const & noise_rate_init,
double const & time_res_init);
34 void SetPixel(
int pixel_id,
double efficiency,
double noise_rate,
double time_res_ns);
38 int Detect(
double const & hit_pos_x,
double const & hit_pos_y,
double const & hit_time_ns,
39 double const & wavelength_nm,
PixelInfo & pixel_info,
double & smeared_time_ns)
const;
42 void GenerateNoise(
double const & time_start_ns,
double const & time_window_ns, std::vector<std::pair<int, double> > &
hits)
const;
48 virtual double GetPDE(
const double & )
const {
return 1.0;}
63 int GenerateNoise(
double const & time_start_ns,
double const & time_window_ns);
66 bool GetNoiseHit(
int & pixel_number,
double & hit_time_ns,
double & smeared_time_ns);
69 void SetDCR(
double const & dcr_Hz);
90 #endif // SensorGridPhotodetector_HH
virtual ~SensorGridPhotodetector()
void SetDCR(double const &dcr_Hz)
Set the dark count rate for all pixels to dcr_Hz.
Common base class for sensor grids.
PixelTraits * pixel_traits
bool GetNoiseHit(int &pixel_number, double &hit_time_ns, double &smeared_time_ns)
Noise hit generator function which has to be called after GenerateNoise() to retrieve the noise hits...
void SetPixel(int pixel_id, double efficiency, double noise_rate, double time_res_ns)
SensorGridBase * sensor_grid
int noisegen_pixel_number
void GenerateNoise(double const &time_start_ns, double const &time_window_ns, std::vector< std::pair< int, double > > &hits) const
Generate noise hits.
void UseInhomogenityFactor(bool flag)
bool use_inhomogenity_factor
void Init(SensorGridBase *sensor_grid_, bool per_pixel_traits_, double const &efficiency_init, double const &noise_rate_init, double const &time_res_init)
Initialization - can also be used in derived class ctors (avoid code duplication).
virtual double GetPDE(const double &) const
Derived classes should override this function and return the average pde of the sensor.
double noisegen_time_start_ns
SensorGridPhotodetector()
double noisegen_current_time_sigma
const SensorGridBase * GetGrid()
int Detect(double const &hit_pos_x, double const &hit_pos_y, double const &hit_time_ns, double const &wavelength_nm, PixelInfo &pixel_info, double &smeared_time_ns) const
Handle photon detection:
double GetSmearedTime(double const &time_value, PixelInfo const &pixel_info) const
Apply time smearing.
double noisegen_time_window_ns
virtual double GetInhomegenityFactor(double const &, double const &) const
Derived classes should override this function to account for spatial PDE deviations (e...