STIR  6.2.0
SinglesRatesForTimeFrames.h
Go to the documentation of this file.
1 //
2 //
3 /*
4  Copyright (C) 2000- 2007, Hammersmith Imanet Ltd
5  Copyright (C) 2021, University College London
6  This file is part of STIR.
7 
8  SPDX-License-Identifier: Apache-2.0
9 
10  See STIR/LICENSE.txt for details
11 */
21 #ifndef __stir_data_SinglesRatesForTimeFrames_H__
22 #define __stir_data_SinglesRatesForTimeFrames_H__
23 
24 #include "stir/data/SinglesRates.h"
25 #include "stir/Array.h"
27 #include "stir/deprecated.h"
28 START_NAMESPACE_STIR
29 
35 {
36 public:
39 
40  // SinglesRatesForTimeFrames(const TimeFrameDefinitions& time_frame_definitions,
41  // const shared_ptr<Scanner>& scanner_sptr);
42 
44 
47  float get_singles(int singles_bin_index, unsigned int frame_number) const;
48 
57  float get_singles(const int singles_bin_index, const double start_time, const double end_time) const override;
58 
60  // for a frame begining at start_time and ending at end_time.
61  FrameSinglesRates STIR_DEPRECATED get_rates_for_frame(double start_time, double end_time) const;
62 
64 
66  void set_singles(const int singles_bin_index, const unsigned time_frame_num, const float new_singles);
67 
69  unsigned int get_num_frames() const;
70 
72  const TimeFrameDefinitions& get_time_frame_definitions() const;
73 
74 protected:
75  Array<2, float> _singles;
76  TimeFrameDefinitions _time_frame_defs;
77 };
78 
79 END_NAMESPACE_STIR
80 
81 #endif
#define STIR_DEPRECATED
Deprecation macro.
Definition: deprecated.h:19
Class used for storing time frame durations.
Definition: TimeFrameDefinitions.h:38
Declaration of class stir::SinglesRates.
Declaration of class stir::TimeFrameDefinitions.
This file declares a deprecation macro.
A single frame of singles information.
Definition: SinglesRates.h:45
defines the Array class for multi-dimensional (numeric) arrays
The base-class for using singles info.
Definition: SinglesRates.h:112
A class for singles rates that are recorded in time frames.
Definition: SinglesRatesForTimeFrames.h:34