#include <BinnedDiffusion_transform.h>
Public Types | |
enum | ImpactDataCalculationStrategy { constant =1, linear =2 } |
Useful to client code to mark a calculation strategy. More... | |
Public Member Functions | |
BinnedDiffusion_transform (const Pimpos &pimpos, const Binning &tbins, double nsigma=3.0, IRandom::pointer fluctuate=nullptr, ImpactDataCalculationStrategy calcstrat=linear) | |
const Pimpos & | pimpos () const |
const Binning & | tbins () const |
bool | add (IDepo::pointer deposition, double sigma_time, double sigma_pitch) |
void | get_charge_vec (std::vector< std::vector< std::tuple< int, int, double > > > &vec_vec_charge, std::vector< int > &vec_impact) |
void | get_charge_matrix (std::vector< Eigen::SparseMatrix< float > * > &vec_spmatrix, std::vector< int > &vec_impact) |
std::pair< double, double > | pitch_range (double nsigma=0.0) const |
std::pair< int, int > | impact_bin_range (double nsigma=0.0) const |
std::pair< double, double > | time_range (double nsigma=0.0) const |
std::pair< int, int > | time_bin_range (double nsigma=0.0) const |
double | get_nsigma () const |
Private Attributes | |
const Pimpos & | m_pimpos |
const Binning & | m_tbins |
double | m_nsigma |
IRandom::pointer | m_fluctuate |
ImpactDataCalculationStrategy | m_calcstrat |
std::pair< int, int > | m_window |
std::map< int, ImpactData::mutable_pointer > | m_impacts |
std::set< std::shared_ptr< GaussianDiffusion > > | m_diffs |
int | m_outside_pitch |
int | m_outside_time |
A BinnedDiffusion_transform maintains an association between impact positions along the pitch direction of a wire plane and the diffused depositions that drift to them.
It covers a fixed and discretely sampled time and pitch domain.
Definition at line 27 of file BinnedDiffusion_transform.h.
Useful to client code to mark a calculation strategy.
Create a BinnedDiffusion_transform.
Arguments are:
Enumerator | |
---|---|
constant | |
linear |
Definition at line 51 of file BinnedDiffusion_transform.h.
Gen::BinnedDiffusion_transform::BinnedDiffusion_transform | ( | const Pimpos & | pimpos, |
const Binning & | tbins, | ||
double | nsigma = 3.0 , |
||
IRandom::pointer | fluctuate = nullptr , |
||
ImpactDataCalculationStrategy | calcstrat = linear |
||
) |
Definition at line 23 of file BinnedDiffusion_transform.cxx.
bool Gen::BinnedDiffusion_transform::add | ( | IDepo::pointer | deposition, |
double | sigma_time, | ||
double | sigma_pitch | ||
) |
Add a deposition and its associated diffusion sigmas. Return false if no activity falls within the domain.
Definition at line 37 of file BinnedDiffusion_transform.cxx.
void Gen::BinnedDiffusion_transform::get_charge_matrix | ( | std::vector< Eigen::SparseMatrix< float > * > & | vec_spmatrix, |
std::vector< int > & | vec_impact | ||
) |
Definition at line 128 of file BinnedDiffusion_transform.cxx.
void Gen::BinnedDiffusion_transform::get_charge_vec | ( | std::vector< std::vector< std::tuple< int, int, double > > > & | vec_vec_charge, |
std::vector< int > & | vec_impact | ||
) |
Unconditionally associate an already built GaussianDiffusion to one impact. Drop any stored ImpactData within the half open impact index range. Return the data in the given impact bin. Note, this bin represents drifted charge between two impact positions. Take care when using BinnedDiffusion_transform and field responses because epsilon above or below the impact position exactly in the middle of two wires drastically different response.
Definition at line 223 of file BinnedDiffusion_transform.cxx.
|
inline |
Definition at line 101 of file BinnedDiffusion_transform.h.
std::pair< int, int > Gen::BinnedDiffusion_transform::impact_bin_range | ( | double | nsigma = 0.0 | ) | const |
Return the half open bin range of impact bins, constrained so that either number is in [0,nimpacts].
Definition at line 439 of file BinnedDiffusion_transform.cxx.
|
inline |
Definition at line 57 of file BinnedDiffusion_transform.h.
std::pair< double, double > Gen::BinnedDiffusion_transform::pitch_range | ( | double | nsigma = 0.0 | ) | const |
Return the range of pitch containing depos out to given nsigma and without bounds checking.
Definition at line 430 of file BinnedDiffusion_transform.cxx.
|
inline |
Definition at line 58 of file BinnedDiffusion_transform.h.
std::pair< int, int > Gen::BinnedDiffusion_transform::time_bin_range | ( | double | nsigma = 0.0 | ) | const |
Return the half open bin range for time bins constrained so that either number is in [0,nticks].
Definition at line 456 of file BinnedDiffusion_transform.cxx.
std::pair< double, double > Gen::BinnedDiffusion_transform::time_range | ( | double | nsigma = 0.0 | ) | const |
Return the range of time containing depos out to given nsigma and without bounds checking.
Definition at line 447 of file BinnedDiffusion_transform.cxx.
|
private |
Definition at line 110 of file BinnedDiffusion_transform.h.
|
private |
Definition at line 118 of file BinnedDiffusion_transform.h.
|
private |
Definition at line 109 of file BinnedDiffusion_transform.h.
|
private |
Definition at line 115 of file BinnedDiffusion_transform.h.
|
private |
Definition at line 108 of file BinnedDiffusion_transform.h.
|
private |
Definition at line 120 of file BinnedDiffusion_transform.h.
|
private |
Definition at line 121 of file BinnedDiffusion_transform.h.
|
private |
Definition at line 101 of file BinnedDiffusion_transform.h.
|
private |
Definition at line 106 of file BinnedDiffusion_transform.h.
|
private |
Definition at line 113 of file BinnedDiffusion_transform.h.