STIR 6.4.0
BinNormalisationFromECAT8.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2000-2007, Hammersmith Imanet Ltd
3 Copyright (C) 2013-2014, 2020, 2023 University College London
4
5 Largely a copy of the ECAT7 version.
6
7 SPDX-License-Identifier: Apache-2.0
8
9 See STIR/LICENSE.txt for details
10*/
19
20#ifndef __stir_recon_buildblock_BinNormalisationFromECAT8_H__
21#define __stir_recon_buildblock_BinNormalisationFromECAT8_H__
22
26#include "stir/ProjData.h"
27#include "stir/shared_ptr.h"
30#include "stir/Scanner.h"
31#include "stir/Array.h"
33#include <string>
34
35using std::string;
36
37START_NAMESPACE_STIR
38START_NAMESPACE_ECAT
39
88 : public RegisteredParsingObject<BinNormalisationFromECAT8, BinNormalisation, BinNormalisationWithCalibration>
89{
90private:
91 using base_type = BinNormalisationWithCalibration;
92
93public:
95 static const char* const registered_name;
96
98
104
106 BinNormalisationFromECAT8(const string& filename);
107
108 Succeeded set_up(const shared_ptr<const ExamInfo>& exam_info_sptr, const shared_ptr<const ProjDataInfo>&) override;
109 float get_uncalibrated_bin_efficiency(const Bin& bin) const override;
110
111 bool use_detector_efficiencies() const;
112 bool use_dead_time() const;
113 bool use_geometric_factors() const;
114 bool use_crystal_interference_factors() const;
115 bool use_axial_effects_factors() const;
116
117private:
118 Array<1, float> axial_t1_array;
119 Array<1, float> axial_t2_array;
120 Array<1, float> trans_t1_array;
121 shared_ptr<SinglesRates> singles_rates_ptr;
122 Array<2, float> geometric_factors;
123 Array<2, float> efficiency_factors;
124 Array<2, float> crystal_interference_factors;
125 Array<1, float> axial_effects;
127 Array<2, int> sino_index;
129 int num_Siemens_sinograms;
130
131 shared_ptr<Scanner> scanner_ptr;
132 int num_transaxial_crystals_per_block;
133 // TODO move to Scanner
134 int num_axial_blocks_per_singles_unit;
135 shared_ptr<const ProjDataInfo> proj_data_info_ptr;
136 shared_ptr<const ProjDataInfo> norm_proj_data_info_sptr;
137 ProjDataInfoCylindricalNoArcCorr const* proj_data_info_cyl_ptr;
138 shared_ptr<const ProjDataInfoCylindricalNoArcCorr> proj_data_info_cyl_uncompressed_ptr;
139 int mash;
140 int num_blocks_per_singles_unit;
141 float calib_factor, cross_calib_factor;
142
143 bool _use_gaps;
144 bool _use_detector_efficiencies;
145 bool _use_dead_time;
146 bool _use_geometric_factors;
147 bool _use_crystal_interference_factors;
148 bool _use_axial_effects_factors;
149 bool _write_components_to_file;
150
151 void read_norm_data(const string& filename);
152 float get_dead_time_efficiency(const DetectionPosition<>& det_pos, const double start_time, const double end_time) const;
153
155 void construct_sino_lookup_table();
156 float find_axial_effects(int ring1, int ring2) const;
157 // parsing stuff
158 void set_defaults() override;
159 void initialise_keymap() override;
160 bool post_processing() override;
161
162 string normalisation_ECAT8_filename;
163};
164
165END_NAMESPACE_ECAT
166END_NAMESPACE_STIR
167
168#endif
defines the stir::Array class for multi-dimensional (numeric) arrays
Declaration of class stir::BinNormalisationWithCalibration.
Declaration of class stir::BinNormalisation.
Declaration of class stir::ProjDataInfoCylindricalNoArcCorr.
Declaration of class stir::ProjData.
Declaration of class stir::RegisteredParsingObject.
Declaration of class stir::Scanner.
Declaration of class stir::SinglesRates.
This class defines multi-dimensional (numeric) arrays.
Definition Array.h:78
A class for storing coordinates and value of a single projection bin.
Definition Bin.h:49
A class for storing coordinates of a detection.
Definition DetectionPosition.h:61
Projection data info for data which are not arc-corrected.
Definition ProjDataInfoCylindricalNoArcCorr.h:83
Parent class for all leaves in a RegisteredObject hierarchy that do parsing of parameter files.
Definition RegisteredParsingObject.h:78
a class containing an enumeration type that can be used by functions to signal successful operation o...
Definition Succeeded.h:44
BinNormalisationFromECAT8()
Default constructor.
Definition BinNormalisationFromECAT8.cxx:178
Succeeded set_up(const shared_ptr< const ExamInfo > &exam_info_sptr, const shared_ptr< const ProjDataInfo > &) override
initialises the object and checks if it can handle such projection data
Definition BinNormalisationFromECAT8.cxx:190
static const char *const registered_name
Name which will be used when parsing a BinNormalisation object.
Definition BinNormalisationFromECAT8.h:95
Import of std::shared_ptr, std::dynamic_pointer_cast and std::static_pointer_cast into the stir names...
Declaration of routines which convert ECAT things into our building blocks and vice versa.