Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Corryvreckan
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Fabian Simon Lex
Corryvreckan
Commits
328502a7
Commit
328502a7
authored
1 year ago
by
Fabian Simon Lex
Browse files
Options
Downloads
Patches
Plain Diff
Added flexibilty to define asymmetric pixels
parent
93c37aed
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/modules/AnalysisDUT/AnalysisDUT.cpp
+9
-4
9 additions, 4 deletions
src/modules/AnalysisDUT/AnalysisDUT.cpp
src/modules/AnalysisDUT/AnalysisDUT.h
+1
-1
1 addition, 1 deletion
src/modules/AnalysisDUT/AnalysisDUT.h
with
10 additions
and
5 deletions
src/modules/AnalysisDUT/AnalysisDUT.cpp
+
9
−
4
View file @
328502a7
...
@@ -31,7 +31,7 @@ AnalysisDUT::AnalysisDUT(Configuration& config, std::shared_ptr<Detector> detect
...
@@ -31,7 +31,7 @@ AnalysisDUT::AnalysisDUT(Configuration& config, std::shared_ptr<Detector> detect
config_
.
setDefault
<
double
>
(
"charge_histo_range"
,
1000.0
);
config_
.
setDefault
<
double
>
(
"charge_histo_range"
,
1000.0
);
config_
.
setDefault
<
int
>
(
"n_raw_bins"
,
1000
);
config_
.
setDefault
<
int
>
(
"n_raw_bins"
,
1000
);
config_
.
setDefault
<
double
>
(
"raw_histo_range"
,
1000.0
);
config_
.
setDefault
<
double
>
(
"raw_histo_range"
,
1000.0
);
config_
.
setDefault
<
double
>
(
"inpixel_bin_size"
,
Units
::
get
<
double
>
(
0.5
,
"um"
));
config_
.
setDefault
<
ROOT
::
Math
::
XYPoint
>
(
"inpixel_bin_size"
,
{
Units
::
get
(
0.5
,
"um"
),
Units
::
get
(
0.5
,
"um"
)
}
);
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"
);
...
@@ -42,7 +42,12 @@ AnalysisDUT::AnalysisDUT(Configuration& config, std::shared_ptr<Detector> detect
...
@@ -42,7 +42,12 @@ AnalysisDUT::AnalysisDUT(Configuration& config, std::shared_ptr<Detector> detect
correlations_
=
config_
.
get
<
bool
>
(
"correlations"
);
correlations_
=
config_
.
get
<
bool
>
(
"correlations"
);
n_chargebins_
=
config_
.
get
<
int
>
(
"n_charge_bins"
);
n_chargebins_
=
config_
.
get
<
int
>
(
"n_charge_bins"
);
charge_histo_range_
=
config_
.
get
<
double
>
(
"charge_histo_range"
);
charge_histo_range_
=
config_
.
get
<
double
>
(
"charge_histo_range"
);
inpixelBinSize_
=
config_
.
get
<
double
>
(
"inpixel_bin_size"
);
if
(
config_
.
getArray
<
double
>
(
"inpixel_bin_size"
).
size
()
==
2
)
{
inpixelBinSize_
=
config_
.
get
<
ROOT
::
Math
::
XYPoint
>
(
"inpixel_bin_size"
);
}
else
{
auto
binsize
=
config_
.
get
<
double
>
(
"inpixel_bin_size"
);
inpixelBinSize_
=
ROOT
::
Math
::
XYPoint
(
binsize
,
binsize
);
}
// if no separate raw histo bin settings are given, use the ones specified for the charge
// if no separate raw histo bin settings are given, use the ones specified for the charge
if
(
config_
.
has
(
"n_charge_bins"
)
&
!
config_
.
has
(
"n_raw_bins"
))
{
if
(
config_
.
has
(
"n_charge_bins"
)
&
!
config_
.
has
(
"n_raw_bins"
))
{
...
@@ -642,8 +647,8 @@ void AnalysisDUT::initialize() {
...
@@ -642,8 +647,8 @@ void AnalysisDUT::initialize() {
-1000,
-1000,
1000);
1000);
auto nbins_x = static_cast<int>(std::ceil(m_detector->getPitch().X() / inpixelBinSize_));
auto nbins_x = static_cast<int>(std::ceil(m_detector->getPitch().X() / inpixelBinSize_
.x()
));
auto nbins_y = static_cast<int>(std::ceil(m_detector->getPitch().Y() / inpixelBinSize_));
auto nbins_y = static_cast<int>(std::ceil(m_detector->getPitch().Y() / inpixelBinSize_
.y()
));
if(nbins_x > 1e4 || nbins_y > 1e4) {
if(nbins_x > 1e4 || nbins_y > 1e4) {
throw InvalidValueError(config_, "
inpixel_bin_size
", "
Too
many
bins
for
in
-
pixel
histograms
.
");
throw InvalidValueError(config_, "
inpixel_bin_size
", "
Too
many
bins
for
in
-
pixel
histograms
.
");
}
}
...
...
This diff is collapsed.
Click to expand it.
src/modules/AnalysisDUT/AnalysisDUT.h
+
1
−
1
View file @
328502a7
...
@@ -130,7 +130,7 @@ namespace corryvreckan {
...
@@ -130,7 +130,7 @@ namespace corryvreckan {
TProfile2D
*
hclusterSize_trackPos_TProfile
;
TProfile2D
*
hclusterSize_trackPos_TProfile
;
// Member variables
// Member variables
double
inpixelBinSize_
;
ROOT
::
Math
::
XYPoint
inpixelBinSize_
;
double
time_cut_frameedge_
;
double
time_cut_frameedge_
;
double
spatial_cut_sensoredge_
;
double
spatial_cut_sensoredge_
;
double
chi2_ndof_cut_
;
double
chi2_ndof_cut_
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment