18 #ifndef __stir_recon_buildblock_PoissonLogLikelihoodWithLinearModelForMean_H__ 19 #define __stir_recon_buildblock_PoissonLogLikelihoodWithLinearModelForMean_H__ 110 template <
typename TargetT>
111 class PoissonLogLikelihoodWithLinearModelForMean :
public GeneralisedObjectiveFunction<TargetT>
114 typedef GeneralisedObjectiveFunction<TargetT> base_type;
132 void compute_sub_gradient_without_penalty(TargetT& gradient,
const TargetT& current_estimate,
const int subset_num)
override;
147 compute_sub_gradient_without_penalty_plus_sensitivity(TargetT& gradient,
const TargetT& current_estimate,
const int subset_num);
162 Succeeded set_up(shared_ptr<TargetT>
const& target_sptr)
override;
165 const TargetT& get_sensitivity()
const;
167 const TargetT& get_subset_sensitivity(
const int subset_num)
const;
170 virtual void add_subset_sensitivity(TargetT& sensitivity,
const int subset_num)
const = 0;
177 bool get_use_subset_sensitivities()
const;
180 bool get_recompute_sensitivity()
const;
184 std::string get_sensitivity_filename()
const;
190 std::string get_subsensitivity_filenames()
const;
199 void set_recompute_sensitivity(
const bool);
200 void set_subset_sensitivity_sptr(
const shared_ptr<TargetT>&,
const int subset_num);
203 void set_use_subset_sensitivities(
const bool);
207 void set_sensitivity_filename(
const std::string&);
215 void set_subsensitivity_filenames(
const std::string&);
221 void fill_nonidentifiable_target_parameters(TargetT& target,
const float value)
const override;
224 std::string sensitivity_filename;
225 std::string subsensitivity_filenames;
226 bool recompute_sensitivity;
227 bool use_subset_sensitivities;
229 VectorWithOffset<shared_ptr<TargetT>> subsensitivity_sptrs;
230 shared_ptr<TargetT> sensitivity_sptr;
233 shared_ptr<TargetT> get_subset_sensitivity_sptr(
const int subset_num)
const;
242 void set_total_or_subset_sensitivities();
246 virtual Succeeded set_up_before_sensitivity(shared_ptr<const TargetT>
const& target_sptr) = 0;
253 void compute_sensitivities();
270 virtual void actual_compute_subset_gradient_without_penalty(TargetT& gradient,
271 const TargetT& current_estimate,
272 const int subset_num,
273 const bool add_sensitivity)
280 void set_defaults()
override;
281 void initialise_keymap()
override;
282 bool post_processing()
override;
Declaration of class stir::GeneralisedObjectiveFunction.