ITK 6.0.0
Insight Toolkit
 
Loading...
Searching...
No Matches
rtkRegularizedConjugateGradientConeBeamReconstructionFilter.h
Go to the documentation of this file.
1/*=========================================================================
2 *
3 * Copyright RTK Consortium
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
8 *
9 * https://www.apache.org/licenses/LICENSE-2.0.txt
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 *
17 *=========================================================================*/
18#ifndef rtkRegularizedConjugateGradientConeBeamReconstructionFilter_h
19#define rtkRegularizedConjugateGradientConeBeamReconstructionFilter_h
20
22#ifdef RTK_USE_CUDA
24#else
26#endif
28
30
31namespace rtk
32{
105
106template <typename TImage>
108 : public rtk::IterativeConeBeamReconstructionFilter<TImage, TImage>
109{
110public:
112
119 typename TImage::template RebindImageType<CovariantVectorForSpatialGradient, TImage::ImageDimension>;
122
124 itkNewMacro(Self);
125
128
130 void
131 SetInputVolume(const TImage * Volume);
132 typename TImage::ConstPointer
134
136 void
137 SetInputProjectionStack(const TImage * Projection);
138 typename TImage::Pointer
140
142 void
143 SetInputWeights(const TImage * Weights);
144 typename TImage::Pointer
146
148 void
149 SetSupportMask(const TImage * SupportMask);
150 typename TImage::ConstPointer
152
158
159 // Regularization steps to perform
160 itkSetMacro(PerformPositivity, bool);
161 itkGetMacro(PerformPositivity, bool);
162 itkSetMacro(PerformTVSpatialDenoising, bool);
163 itkGetMacro(PerformTVSpatialDenoising, bool);
164 itkSetMacro(PerformWaveletsSpatialDenoising, bool);
165 itkGetMacro(PerformWaveletsSpatialDenoising, bool);
166 itkSetMacro(PerformSoftThresholdOnImage, bool);
167 itkGetMacro(PerformSoftThresholdOnImage, bool);
168
169 // Regularization parameters
170 itkSetMacro(GammaTV, float);
171 itkGetMacro(GammaTV, float);
172 itkSetMacro(SoftThresholdWavelets, float);
173 itkGetMacro(SoftThresholdWavelets, float);
174 itkSetMacro(SoftThresholdOnImage, float);
175 itkGetMacro(SoftThresholdOnImage, float);
176
178 itkGetMacro(NumberOfLevels, unsigned int);
179 itkSetMacro(NumberOfLevels, unsigned int);
180
182 itkGetMacro(Order, unsigned int);
183 itkSetMacro(Order, unsigned int);
184
185 // Iterations
186 itkSetMacro(MainLoop_iterations, int);
187 itkGetMacro(MainLoop_iterations, int);
188 itkSetMacro(CG_iterations, int);
189 itkGetMacro(CG_iterations, int);
190 itkSetMacro(TV_iterations, int);
191 itkGetMacro(TV_iterations, int);
192
193 // Geometry
194 itkSetObjectMacro(Geometry, ThreeDCircularProjectionGeometry);
195 itkGetModifiableObjectMacro(Geometry, ThreeDCircularProjectionGeometry);
196
198 itkSetMacro(Preconditioned, bool);
199 itkGetMacro(Preconditioned, bool);
200
202 itkSetMacro(Tikhonov, float);
203 itkGetMacro(Tikhonov, float);
204 itkSetMacro(Gamma, float);
205 itkGetMacro(Gamma, float);
206
208 itkSetMacro(CudaConjugateGradient, bool);
209 itkGetMacro(CudaConjugateGradient, bool);
210
212 itkSetMacro(DisableDisplacedDetectorFilter, bool);
213 itkGetMacro(DisableDisplacedDetectorFilter, bool);
214
215protected:
218
220 void
221 VerifyPreconditions() const override;
222
224 void
225 GenerateData() override;
226
227 void
229
230 void
232
233 // Inputs are not supposed to occupy the same physical space,
234 // so there is nothing to verify
235 void
236 VerifyInputInformation() const override
237 {}
238
245
246 // Booleans for each regularization (should it be performed or not)
247 // as well as to choose whether CG should be on GPU or not
253
254 // Regularization parameters
256 float m_Gamma;
260 bool m_DimensionsProcessedForTV[TImage::ImageDimension];
263
265 unsigned int m_Order;
266 unsigned int m_NumberOfLevels;
267
270
271 // Iterations
275
276 // Geometry
278};
279} // namespace rtk
280
281
282#ifndef ITK_MANUAL_INSTANTIATION
283# include "rtkRegularizedConjugateGradientConeBeamReconstructionFilter.hxx"
284#endif
285
286#endif
A templated class holding a n-Dimensional covariant vector.
Implements transparent reference counting.
Set image values to a user-specified value if they are below, above, or outside threshold values.
Deconstructs an image, soft thresholds its wavelets coefficients, then reconstructs.
Mother class for cone beam reconstruction filters which need runtime selection of their forward and b...
enum { FP_JOSEPH=0, FP_CUDARAYCAST=2, FP_JOSEPHATTENUATED=3, FP_ZENG=4, FP_CUDAWARP=5, FP_CUDAZENG=6 } ForwardProjectionType
enum { BP_VOXELBASED=0, BP_JOSEPH=1, BP_CUDAVOXELBASED=2, BP_CUDARAYCAST=4, BP_JOSEPHATTENUATED=5, BP_ZENG=6, BP_CUDAWARP=7, BP_CUDAZENG=8 } BackProjectionType
void VerifyInputInformation() const override
Verifies that the input images occupy the same physical space and the each index is at the same physi...
typename TImage::template RebindImageType< CovariantVectorForSpatialGradient, TImage::ImageDimension > GradientImageType
itk::CovariantVector< typename TImage::ValueType, TImage::ImageDimension > CovariantVectorForSpatialGradient
rtk::TotalVariationDenoisingBPDQImageFilter< TImage, GradientImageType > TVDenoisingFilterType
Projection geometry for a source and a 2-D flat panel.
Applies a total variation denoising, only alm_SingularValueThresholdFilterong the dimensions specifie...
#define itkSetMacro(name, type)