Skip to content
Snippets Groups Projects
Commit c6716434 authored by Simon Spannagel's avatar Simon Spannagel
Browse files

AnalysisDUT: allow switching off the discard of neighbor pixels

parent c6445b9c
No related branches found
No related tags found
No related merge requests found
...@@ -22,6 +22,7 @@ AnalysisDUT::AnalysisDUT(Configuration& config, std::shared_ptr<Detector> detect ...@@ -22,6 +22,7 @@ AnalysisDUT::AnalysisDUT(Configuration& config, std::shared_ptr<Detector> detect
config_.setDefault<double>("time_cut_frameedge", Units::get<double>(20, "ns")); config_.setDefault<double>("time_cut_frameedge", Units::get<double>(20, "ns"));
config_.setDefault<double>("spatial_cut_sensoredge", 0.5); config_.setDefault<double>("spatial_cut_sensoredge", 0.5);
config_.setDefault<bool>("ignore_neighbors_masked", true);
config_.setDefault<double>("chi2ndof_cut", 3.); config_.setDefault<double>("chi2ndof_cut", 3.);
config_.setDefault<bool>("use_closest_cluster", true); config_.setDefault<bool>("use_closest_cluster", true);
config_.setDefault<int>("n_time_bins", 20000); config_.setDefault<int>("n_time_bins", 20000);
...@@ -35,6 +36,7 @@ AnalysisDUT::AnalysisDUT(Configuration& config, std::shared_ptr<Detector> detect ...@@ -35,6 +36,7 @@ AnalysisDUT::AnalysisDUT(Configuration& config, std::shared_ptr<Detector> detect
time_cut_frameedge_ = config_.get<double>("time_cut_frameedge"); time_cut_frameedge_ = config_.get<double>("time_cut_frameedge");
spatial_cut_sensoredge_ = config_.get<double>("spatial_cut_sensoredge"); spatial_cut_sensoredge_ = config_.get<double>("spatial_cut_sensoredge");
ignore_neighbors_masked_ = config_.get<bool>("ignore_neighbors_masked");
chi2_ndof_cut_ = config_.get<double>("chi2ndof_cut"); chi2_ndof_cut_ = config_.get<double>("chi2ndof_cut");
use_closest_cluster_ = config_.get<bool>("use_closest_cluster"); use_closest_cluster_ = config_.get<bool>("use_closest_cluster");
n_timebins_ = config_.get<int>("n_time_bins"); n_timebins_ = config_.get<int>("n_time_bins");
...@@ -683,7 +685,7 @@ bool AnalysisDUT::acceptTrackDUT(const std::shared_ptr<Track>& track) { ...@@ -683,7 +685,7 @@ bool AnalysisDUT::acceptTrackDUT(const std::shared_ptr<Track>& track) {
} }
// Check that it doesn't go through/near a masked pixel // Check that it doesn't go through/near a masked pixel
if(m_detector->hitMasked(track.get(), 1.)) { if(m_detector->hitMasked(track.get(), (ignore_neighbors_masked_ ? 1.0 : 0.0))) {
LOG(DEBUG) << " - track close to masked pixel"; LOG(DEBUG) << " - track close to masked pixel";
hCutHisto->Fill(ETrackSelection::kCloseToMask); hCutHisto->Fill(ETrackSelection::kCloseToMask);
num_tracks_++; num_tracks_++;
......
...@@ -136,6 +136,7 @@ namespace corryvreckan { ...@@ -136,6 +136,7 @@ namespace corryvreckan {
ROOT::Math::XYPoint inpixelBinSize_; ROOT::Math::XYPoint inpixelBinSize_;
double time_cut_frameedge_; double time_cut_frameedge_;
double spatial_cut_sensoredge_; double spatial_cut_sensoredge_;
bool ignore_neighbors_masked_;
double chi2_ndof_cut_; double chi2_ndof_cut_;
bool use_closest_cluster_; bool use_closest_cluster_;
int n_timebins_; int n_timebins_;
......
...@@ -11,10 +11,12 @@ ...@@ -11,10 +11,12 @@
### Description ### Description
Generic analysis module for all types of detectors. Produces a number of commonly used plots to gauge detector performance and allows to discard tracks based on their chi2/ndf value. Generic analysis module for all types of detectors. Produces a number of commonly used plots to gauge detector performance and allows to discard tracks based on their chi2/ndf value.
If a region of interest (ROI) is defined for the detector under investigation, only tracks from within this region are evaluated, all others are discarded. If a region of interest (ROI) is defined for the detector under investigation, only tracks from within this region are evaluated, all others are discarded.
Tracks going through pixels neighboring a masked pixel are ignored when `ignore_neighbors_masked` is set to `true` to avoid contamination.
### Parameters ### Parameters
* `time_cut_frameedge`: Parameter to discard telescope tracks at the frame edges (start and end of the current CLICpix2 frame). Defaults to `20ns`. * `time_cut_frameedge`: Parameter to discard telescope tracks at the frame edges (start and end of the current CLICpix2 frame). Defaults to `20ns`.
* `spatial_cut_sensoredge`: Parameter to discard telescope tracks at the sensor edges in fractions of pixel pitch. Defaults to `0.5`. * `spatial_cut_sensoredge`: Parameter to discard telescope tracks at the sensor edges in fractions of pixel pitch. Defaults to `0.5`.
* `ignore_neighbors_masked`: Boolean so select whether to exclude tracks which go through neighbors of masked pixels to avoid influencing their efficiency. Defaults to `true`.
* `chi2ndof_cut`: Acceptance criterion for the maximum telescope tracks chi2/ndf, defaults to a value of `3`. * `chi2ndof_cut`: Acceptance criterion for the maximum telescope tracks chi2/ndf, defaults to a value of `3`.
* `use_closest_cluster`: If `true` the cluster with the smallest distance to the track is used if a track has more than one associated cluster. If `false`, loop over all associated clusters. Defaults to `true`. * `use_closest_cluster`: If `true` the cluster with the smallest distance to the track is used if a track has more than one associated cluster. If `false`, loop over all associated clusters. Defaults to `true`.
* `n_time_bins`: Number of bins in the time residual and correlation histograms. Defaults to `20000`. * `n_time_bins`: Number of bins in the time residual and correlation histograms. Defaults to `20000`.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment