ITK  6.0.0
Insight Toolkit
itkStatisticsAlgorithm.h
Go to the documentation of this file.
1/*=========================================================================
2 *
3 * Copyright NumFOCUS
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 itkStatisticsAlgorithm_h
19#define itkStatisticsAlgorithm_h
20
21#include "itkSubsample.h"
22
23namespace itk
24{
25namespace Statistics
26{
27namespace Algorithm
28{
29template <typename TSize>
30TSize
31FloorLog(TSize size);
32
33template <typename TValue>
34TValue
35MedianOfThree(const TValue a, const TValue b, const TValue c);
36
52template <typename TSample>
53void
54FindSampleBound(const TSample * sample,
55 const typename TSample::ConstIterator & begin,
56 const typename TSample::ConstIterator & end,
57 typename TSample::MeasurementVectorType & min,
58 typename TSample::MeasurementVectorType & max);
59
61template <typename TSubsample>
62void
63FindSampleBoundAndMean(const TSubsample * sample,
64 int beginIndex,
65 int endIndex,
66 typename TSubsample::MeasurementVectorType & min,
67 typename TSubsample::MeasurementVectorType & max,
68 typename TSubsample::MeasurementVectorType & mean);
69
91template <typename TSubsample>
92int
93Partition(TSubsample * sample,
94 unsigned int activeDimension,
95 int beginIndex,
96 int endIndex,
97 const typename TSubsample::MeasurementType partitionValue);
98
116template <typename TSubsample>
117typename TSubsample::MeasurementType
118QuickSelect(TSubsample * sample,
119 unsigned int activeDimension,
120 int beginIndex,
121 int endIndex,
122 int kth,
123 typename TSubsample::MeasurementType medianGuess);
124
139template <typename TSubsample>
140typename TSubsample::MeasurementType
141QuickSelect(TSubsample * sample, unsigned int activeDimension, int beginIndex, int endIndex, int kth);
142
151template <typename TSubsample>
152typename TSubsample::MeasurementType
153NthElement(TSubsample * sample, unsigned int activeDimension, int beginIndex, int endIndex, int nth);
154
155template <typename TSubsample>
156void
157InsertSort(TSubsample * sample, unsigned int activeDimension, int beginIndex, int endIndex);
158
159template <typename TSubsample>
160void
161DownHeap(TSubsample * sample, unsigned int activeDimension, int beginIndex, int endIndex, int node);
162
163template <typename TSubsample>
164void
165HeapSort(TSubsample * sample, unsigned int activeDimension, int beginIndex, int endIndex);
166
167template <typename TSubsample>
168void
169IntrospectiveSortLoop(TSubsample * sample,
170 unsigned int activeDimension,
171 int beginIndex,
172 int endIndex,
173 int depthLimit,
174 int sizeThreshold);
175
176template <typename TSubsample>
177void
178IntrospectiveSort(TSubsample * sample, unsigned int activeDimension, int beginIndex, int endIndex, int sizeThreshold);
179
180} // end of namespace Algorithm
181} // end of namespace Statistics
182} // end of namespace itk
183
184#ifndef ITK_MANUAL_INSTANTIATION
185# include "itkStatisticsAlgorithm.hxx"
186#endif
187
188#endif // #ifndef itkStatisticsAlgorithm_h
Algorithm or implementation used in the dilation/erosion operations.
void IntrospectiveSort(TSubsample *sample, unsigned int activeDimension, int beginIndex, int endIndex, int sizeThreshold)
void FindSampleBoundAndMean(const TSubsample *sample, int beginIndex, int endIndex, typename TSubsample::MeasurementVectorType &min, typename TSubsample::MeasurementVectorType &max, typename TSubsample::MeasurementVectorType &mean)
void InsertSort(TSubsample *sample, unsigned int activeDimension, int beginIndex, int endIndex)
void IntrospectiveSortLoop(TSubsample *sample, unsigned int activeDimension, int beginIndex, int endIndex, int depthLimit, int sizeThreshold)
TSize FloorLog(TSize size)
int Partition(TSubsample *sample, unsigned int activeDimension, int beginIndex, int endIndex, const typename TSubsample::MeasurementType partitionValue)
TSubsample::MeasurementType NthElement(TSubsample *sample, unsigned int activeDimension, int beginIndex, int endIndex, int nth)
void FindSampleBound(const TSample *sample, const typename TSample::ConstIterator &begin, const typename TSample::ConstIterator &end, typename TSample::MeasurementVectorType &min, typename TSample::MeasurementVectorType &max)
TSubsample::MeasurementType QuickSelect(TSubsample *sample, unsigned int activeDimension, int beginIndex, int endIndex, int kth, typename TSubsample::MeasurementType medianGuess)
void DownHeap(TSubsample *sample, unsigned int activeDimension, int beginIndex, int endIndex, int node)
TValue MedianOfThree(const TValue a, const TValue b, const TValue c)
void HeapSort(TSubsample *sample, unsigned int activeDimension, int beginIndex, int endIndex)
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....