perfusion.hh
Go to the documentation of this file.
1 /* -*- mia-c++ -*-
2  *
3  * This file is part of MIA - a toolbox for medical image analysis
4  * Copyright (c) Leipzig, Madrid 1999-2013 Gert Wollny
5  *
6  * MIA is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 3 of the License, or
9  * (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with MIA; if not, see <http://www.gnu.org/licenses/>.
18  *
19  */
20 
21 #ifndef mia_2d_perfusion_hh
22 #define mia_2d_perfusion_hh
23 
24 #include <vector>
25 #include <mia/core/dictmap.hh>
27 #include <mia/2d/image.hh>
28 #include <mia/2d/filter.hh>
29 
30 
32 
42 public:
48  bs_unknown
49  };
56  C2DPerfusionAnalysis(size_t components, bool normalize,
57  bool meanstrip);
58 
59 
64  void set_max_ica_iterations(size_t maxiter);
65 
67 
73  bool run(const std::vector<C2DFImage>& series);
74 
75 
79  bool has_movement() const;
80 
95  P2DFilter get_crop_filter(float scale, C2DBounds& crop_start,
96  EBoxSegmentation approach,
97  const std::string& save_features="") const;
98 
99 
103  std::vector<C2DFImage> get_references() const;
104 
110  void set_approach(size_t approach);
111 
115  int get_RV_peak_idx() const __attribute__((deprecated));
116 
120  int get_RV_idx() const;
121 
125  int get_LV_peak_idx() const __attribute__((deprecated));
126 
130  int get_LV_idx() const;
131 
132 
136  int get_perfusion_idx() const;
137 
141  static TDictMap<EBoxSegmentation> segmethod_dict;
142 
146  void set_use_guess_model();
147 
148 
153  void save_coefs(const std::string& coefs_name)const;
154 
159  void save_feature_images(const std::string& base_name)const;
160 
165  P2DImage get_feature_image(int index) const;
166 
170  int get_LV_peak_time() const;
171 
175  int get_RV_peak_time() const;
176 
177 private:
178  struct C2DPerfusionAnalysisImpl *impl;
179 
180 };
181 
183 
184 #endif