NifTK  16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
itkMammographicTumourDistribution.h
Go to the documentation of this file.
1 /*=============================================================================
2 
3  NifTK: A software platform for medical image computing.
4 
5  Copyright (c) University College London (UCL). All rights reserved.
6 
7  This software is distributed WITHOUT ANY WARRANTY; without even
8  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
9  PURPOSE.
10 
11  See LICENSE.txt in the top level directory for details.
12 
13 =============================================================================*/
14 
15 #ifndef itkMammographicTumourDistribution_h
16 #define itkMammographicTumourDistribution_h
17 
18 #include <itkMammogramAnalysis.h>
19 
20 
31 namespace itk
32 {
33 
34 
35 // -----------------------------------------------------------------------------------
36 // Class to store the data for control and diagnostic images of a patient
37 // -----------------------------------------------------------------------------------
38 
39 template <class InputPixelType, unsigned int InputDimension=2>
41  : public MammogramAnalysis< InputPixelType, InputDimension >
42 {
43 public:
44 
47  typedef SmartPointer<Self> Pointer;
48  typedef SmartPointer<const Self> ConstPointer;
49 
50  itkNewMacro(Self);
51  itkTypeMacro(MammographicTumourDistribution, Object);
52 
53  itkStaticConstMacro( ParametricDimension, unsigned int, 2 );
54  itkStaticConstMacro( DataDimension, unsigned int, 1 );
55 
56  typedef typename Superclass::ImageType ImageType;
57  typedef typename Superclass::OutputImageType OutputImageType;
58  typedef typename Superclass::LabelImageType LabelImageType;
59  typedef typename Superclass::ImageTypeUCHAR ImageTypeUCHAR;
60 
62  typedef typename Superclass::PolygonType PolygonType;
63 
64  typedef typename Superclass::LeftOrRightSideCalculatorType LeftOrRightSideCalculatorType;
65 
66  void SetOutputCSV( std::ofstream *foutOutputCSV ) { m_foutOutputCSV = foutOutputCSV; };
67 
68  void WriteDataToCSVFile( std::ofstream *foutCSV );
69 
70  // Returns false is failed to complete
71  bool Compute( void );
72 
73 protected:
74 
77 
80 
82  void AddPointToTumourPolygon( typename PolygonType::Pointer &polygon, int i, int j);
83 
85  typename ImageType::Pointer DrawTumourOnReferenceImage();
86 
88  void RunRegistration();
89 
91  std::ofstream *m_foutOutputCSV;
92 
93 private:
94 
95  MammographicTumourDistribution(const Self&); //purposely not implemented
96  void operator=(const Self&); //purposely not implemented
97 
98 };
99 
100 } // namespace itk
101 
102 
103 #ifndef ITK_MANUAL_INSTANTIATION
104 #include "itkMammographicTumourDistribution.txx"
105 #endif
106 
107 #endif
108 
109 
Superclass::LeftOrRightSideCalculatorType LeftOrRightSideCalculatorType
Definition: itkMammographicTumourDistribution.h:64
Definition: itkMammographicTumourDistribution.h:40
SmartPointer< const Self > ConstPointer
Definition: itkMammographicTumourDistribution.h:48
Definition: niftkITKAffineResampleImage.cxx:74
Superclass::ReaderType ReaderType
Definition: itkMammographicTumourDistribution.h:61
MammogramAnalysis< InputPixelType, InputDimension > Superclass
Definition: itkMammographicTumourDistribution.h:46
std::ofstream * m_foutOutputCSV
The output CSV file stream.
Definition: itkMammographicTumourDistribution.h:91
Superclass::OutputImageType OutputImageType
Definition: itkMammographicTumourDistribution.h:57
void SetOutputCSV(std::ofstream *foutOutputCSV)
Definition: itkMammographicTumourDistribution.h:66
Superclass::LabelImageType LabelImageType
Definition: itkMammographicTumourDistribution.h:58
itk::ImageSeriesReader< ImageType > ReaderType
Definition: niftkBreastDicomSeriesReadImageWrite.cxx:169
itk::Image< PixelType, Dimension > ImageType
Definition: niftkBreastDCEandADC.cxx:91
SmartPointer< Self > Pointer
Definition: itkMammographicTumourDistribution.h:47
Definition: itkMammogramAnalysis.h:193
Superclass::PolygonType PolygonType
Definition: itkMammographicTumourDistribution.h:62
Superclass::ImageTypeUCHAR ImageTypeUCHAR
Definition: itkMammographicTumourDistribution.h:59
MammographicTumourDistribution Self
Definition: itkMammographicTumourDistribution.h:45
Superclass::ImageType ImageType
Definition: itkMammographicTumourDistribution.h:56