STIR 6.4.0
LmToProjDataBootstrap.h
Go to the documentation of this file.
1//
2//
13/*
14 Copyright (C) 2003- 2011, Hammersmith Imanet
15 Copyright (C) 2019, National Physical Laboratory
16 Copyright (C) 2019, University College of London
17 This file is part of STIR.
18
19 SPDX-License-Identifier: Apache-2.0
20
21 See STIR/LICENSE.txt for details
22*/
23
24#ifndef __stir_listmode_LmToProjDataBootstrap_H__
25#define __stir_listmode_LmToProjDataBootstrap_H__
26
28#include <vector>
29
30START_NAMESPACE_STIR
31
67template <typename LmToProjDataT>
68class LmToProjDataBootstrap : public LmToProjDataT
69{
70
71public:
73 LmToProjDataBootstrap(const char* const par_filename);
75
76 LmToProjDataBootstrap(const char* const par_filename, const unsigned int seed);
77
78 Succeeded set_up() override;
79
80protected:
82
83 void start_new_time_frame(const unsigned int new_frame_num) override;
84
85 void get_bin_from_event(Bin& bin, const ListEvent&) const override;
86
87 // \name parsing variables
89
91 unsigned int seed;
93
94private:
95 typedef LmToProjDataT base_type;
96 typedef std::vector<unsigned char> replication_type;
97
98 replication_type num_times_to_replicate;
99 mutable replication_type::const_iterator num_times_to_replicate_iter;
100 void set_defaults() override;
101 void initialise_keymap() override;
102 bool post_processing() override;
103};
104
105END_NAMESPACE_STIR
106
107#endif
Declaration of the stir::LmToProjData class which is used to bin listmode data to (3d) sinograms.
A class for storing coordinates and value of a single projection bin.
Definition Bin.h:49
Class for storing and using gamma events from a list mode file.
Definition ListEvent.h:46
LmToProjDataBootstrap(const char *const par_filename)
Constructor that parses from a file.
Definition LmToProjDataBootstrap.cxx:61
unsigned int seed
used to seed the pseudo-random number generator
Definition LmToProjDataBootstrap.h:91
void start_new_time_frame(const unsigned int new_frame_num) override
will be called when a new time frame starts
Definition LmToProjDataBootstrap.cxx:117
a class containing an enumeration type that can be used by functions to signal successful operation o...
Definition Succeeded.h:44