STIR  6.2.0
CListModeDataROOT.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2015, 2016 University of Leeds
3  Copyright (C) 2016, 2017 UCL
4  Copyright (C) 2016, University of Hull
5  This file is part of STIR.
6 
7  SPDX-License-Identifier: Apache-2.0
8 
9  See STIR/LICENSE.txt for details
10 */
21 #ifndef __stir_listmode_CListModeDataROOT_H__
22 #define __stir_listmode_CListModeDataROOT_H__
23 
27 #include "stir/KeyParser.h"
28 
29 START_NAMESPACE_STIR
30 
107 {
108 public:
110  CListModeDataROOT(const std::string& hroot_filename_prefix);
111 
113  std::string get_name() const override;
115  void set_defaults();
116 
117  shared_ptr<CListRecord> get_empty_record_sptr() const override;
118 
119  Succeeded get_next_record(CListRecord& record) const override;
120 
121  Succeeded reset() override;
122 
123  SavedPosition save_get_position() override;
124 
125  Succeeded set_get_position(const SavedPosition&) override;
126 
127  bool has_delayeds() const override { return true; }
128 
129  inline unsigned long int get_total_number_of_events() const override;
130 
131 private:
133  Succeeded check_scanner_definition(std::string& ret);
135  Succeeded check_scanner_match_geometry(std::string& ret, const shared_ptr<Scanner>& scanner_sptr);
136 
138  std::string hroot_filename;
139 
141  shared_ptr<InputStreamFromROOTFile> root_file_sptr;
142 
146 
147  std::string originating_system;
150 
151  int num_rings;
154  int num_detectors_per_ring;
156  int max_num_non_arccorrected_bins;
158  int default_num_arccorrected_bins;
160  float view_offset;
162  float inner_ring_diameter;
164  float average_depth_of_interaction;
166  float ring_spacing;
168  float bin_size;
170 
172 
177  int max_num_timing_bins;
178 
179  float size_timing_bin;
180 
181  float timing_resolution;
182 
183  int tof_mash_factor;
185 
187 
188  float energy_resolution;
189 
190  float reference_energy;
192 
193 
194  KeyParser parser;
195 
196  Succeeded open_lm_file();
197 };
198 
199 END_NAMESPACE_STIR
200 
201 #endif
The base class for reading PET (i.e. coincidence) list mode data.The only difference w...
Definition: CListModeData.h:50
A class to parse Interfile headers.
Definition: KeyParser.h:161
Declaration of class stir::KeyParser.
unsigned int SavedPosition
Use this typedef for save/set_get_position.
Definition: ListModeData.h:130
Class for records in a PET list mode file.
Definition: CListRecord.h:66
Classes for listmode events for GATE simulated ROOT data.
Declaration of class stir::CListModeData.
class that reads ROOT files, generated by GATE, as listmode data.
Definition: CListModeDataROOT.h:106
Declaration of class stir::InputStreamFromROOTFile.
a class containing an enumeration type that can be used by functions to signal successful operation o...
Definition: Succeeded.h:43
bool has_delayeds() const override
Return if the file stores delayed events as well (as opposed to prompts)
Definition: CListModeDataROOT.h:127