STIR 6.5.0
BinNormalisationFromPETSIRD.h
Go to the documentation of this file.
1//
2//
12/*
13 Copyright (C) 2025, 2026, University Medical Center Groningen
14 Copyright (C) 2025, 2026, London South Bank University
15 This file is part of STIR.
16
17 SPDX-License-Identifier: Apache-2.0
18
19 See STIR/LICENSE.txt for details
20*/
21
22#ifndef __stir_recon_buildblock_BinNormalisationFromPETSIRD_H__
23#define __stir_recon_buildblock_BinNormalisationFromPETSIRD_H__
24
28#include "stir/shared_ptr.h"
29#include "stir/PETSIRDInfo.h"
30#include "stir/Array.h"
31
32using std::string;
33
34START_NAMESPACE_STIR
35
36class BinNormalisationFromPETSIRD
37 : public RegisteredParsingObject<BinNormalisationFromPETSIRD, BinNormalisation, BinNormalisationWithCalibration>
38{
39private:
40 using base_type = BinNormalisationWithCalibration;
41
42public:
44 static const char* const registered_name;
45
46 BinNormalisationFromPETSIRD();
47
48 BinNormalisationFromPETSIRD(const std::string& filename);
49
50 Succeeded set_up(const shared_ptr<const ExamInfo>& exam_info_sptr, const shared_ptr<const ProjDataInfo>&) override;
51
52 float get_uncalibrated_bin_efficiency(const Bin& bin) const override;
53
54 inline bool with_detector_efficiencies() const { return m_with_detector_efficiencies; }
55 inline bool use_dead_time() const { return m_use_dead_time; }
56 inline bool with_geometric_factors() const { return m_with_geometric_factors; }
57
58private:
59 bool use_hdf5;
60
61 void set_defaults() override;
62
63 void initialise_keymap() override;
64
65 bool post_processing() override;
66
67 void read_norm_data(const string& filename);
68
69 string normalisation_filename;
70
72 bool m_with_detector_efficiencies;
74 bool m_use_dead_time;
76 bool m_with_geometric_factors;
77 // shared_ptr<PETSIRDInfo> petsird_info_sptr;
78 shared_ptr<petsird::PETSIRDReaderBase> petsird_data_sptr;
79
80 shared_ptr<petsird::ScannerInformation> scanner_info_sptr;
81
82 shared_ptr<const PETSIRDInfo> petsird_info_sptr;
83 // dead time blocks copied as stored in the PETSIRD file
84 std::vector<petsird::DeadTimeTimeBlock> dead_time_blocks;
85 float get_dead_time_efficiency(const DetectionPosition<>& det_pos, const double start_time, const double end_time) const;
86};
87
88END_NAMESPACE_STIR
89
90#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::PETSIRDInfo.
Declaration of class stir::RegisteredParsingObject.
Import of std::shared_ptr, std::dynamic_pointer_cast and std::static_pointer_cast into the stir names...