iRoCS Toolbox  1.1.0
SegmentationModel.hh
Go to the documentation of this file.
1 /**************************************************************************
2  *
3  * Copyright (C) 2015 Margret Keuper, Thorsten Falk
4  *
5  * Image Analysis Lab, University of Freiburg, Germany
6  *
7  * This program is free software; you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation; either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, write to the Free Software Foundation,
19  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20  *
21  **************************************************************************/
22 
23 #ifndef LIBSEGMENTATION_SEGMENTATION_MODEL_HH
24 #define LIBSEGMENTATION_SEGMENTATION_MODEL_HH
25 
26 #ifdef HAVE_CONFIG_H
27 #include <config.hh>
28 #endif
29 
30 #include <string>
31 #include <vector>
32 namespace segmentation{
33 // forward declarations
34 template<typename T>
35 class MahalanobisDistance;
36 
37 template<typename T> class NormalPDF;
38 template<typename T>
44 public:
46  void appendPdf(NormalPDF<T> *pdf);
47  void clear();
48  size_t size();
49 
54  void load(const std::string &filename);
59  void save(const std::string &filename);
60 
64  std::vector<NormalPDF<T>*> pdfs_;
65 };
66 
67 } //namespace segmentation
68 #endif //LIBSEGMENTATION_SEGMENTATION_MODEL_HH
void save(const std::string &filename)
loads model from hdf5-file
~SegmentationModel()
A segmentation model ist just a list of Normal PDFs and the parameters that where used for sampling...
std::vector< NormalPDF< T > * > pdfs_
void appendPdf(NormalPDF< T > *pdf)
void load(const std::string &filename)
saves model as hdf5-file
Encapsulates a normal pdf.
Definition: NormalPDF.hh:40
T sampling_dist_um_
sampling distance in um