ITK  4.9.0
Insight Segmentation and Registration Toolkit
Public Types | Public Member Functions | Protected Member Functions | Private Attributes | Static Private Attributes | List of all members
itk::ResourceProbe< ValueType, MeanType > Class Template Referenceabstract

#include <itkResourceProbe.h>

+ Inheritance diagram for itk::ResourceProbe< ValueType, MeanType >:
+ Collaboration diagram for itk::ResourceProbe< ValueType, MeanType >:

Detailed Description

template<typename ValueType, typename MeanType>
class itk::ResourceProbe< ValueType, MeanType >

Computes the change of a value between two points in code.

This class is the base class of all the probes (time, memory, etc.) between the execution of two pieces of code. It can be started and stopped in order to evaluate the execution over multiple passes.

See Also
TimeResourceProbe, MemoryResourceProbe

Definition at line 43 of file itkResourceProbe.h.

Public Types

typedef SizeValueType CountType
 

Public Member Functions

virtual void ExpandedReport (std::ostream &os=std::cout, bool printSystemInfo=true, bool printReportHead=true)
 
virtual ValueType GetInstantValue (void) const =0
 
virtual ValueType GetMaximum () const
 
virtual MeanType GetMean () const
 
virtual ValueType GetMinimum () const
 
virtual std::string GetNameOfProbe () const
 
CountType GetNumberOfIteration () const
 
CountType GetNumberOfStarts () const
 
CountType GetNumberOfStops () const
 
virtual ValueType GetStandardDeviation ()
 
virtual ValueType GetTotal () const
 
std::string GetType () const
 
std::string GetUnit () const
 
virtual void PrintSystemInformation (std::ostream &os=std::cout)
 
virtual void Report (std::ostream &os=std::cout, bool printSystemInfo=true, bool printReportHead=true)
 
virtual void Reset ()
 
 ResourceProbe (const std::string &type, const std::string &unit)
 
virtual void SetNameOfProbe (const char *nameOfProbe)
 
virtual void Start ()
 
virtual void Stop ()
 
virtual ~ResourceProbe ()
 

Protected Member Functions

virtual void GetSystemInformation ()
 
virtual void PrintExpandedReportHead (std::ostream &os=std::cout)
 
virtual void PrintReportHead (std::ostream &os=std::cout)
 
virtual void UpdateMinimumMaximumMeasuredValue (ValueType value)
 

Private Attributes

vcl_size_t m_AvailablePhysicalMemory
 
vcl_size_t m_AvailableVirtualMemory
 
bool m_Is64Bits
 
std::string m_ITKVersion
 
ValueType m_MaximumValue
 
MeanType m_MeanValue
 
ValueType m_MinimumValue
 
std::string m_NameOfProbe
 
unsigned int m_NumberOfAvailableCore
 
CountType m_NumberOfIteration
 
unsigned int m_NumberOfLogicalCPU
 
unsigned int m_NumberOfPhysicalCPU
 
CountType m_NumberOfStarts
 
CountType m_NumberOfStops
 
std::string m_OSName
 
std::string m_OSPlatform
 
std::string m_OSRelease
 
std::string m_OSVersion
 
std::vector< ValueType > m_ProbeValueList
 
int m_ProcessorCacheSize
 
float m_ProcessorClockFrequency
 
std::string m_ProcessorName
 
ValueType m_StandardDeviation
 
ValueType m_StartValue
 
std::string m_SystemName
 
vcl_size_t m_TotalPhysicalMemory
 
ValueType m_TotalValue
 
vcl_size_t m_TotalVirtualMemory
 
std::string m_TypeString
 
std::string m_UnitString
 

Static Private Attributes

static const unsigned int tabwidth = 15
 

Member Typedef Documentation

template<typename ValueType, typename MeanType>
typedef SizeValueType itk::ResourceProbe< ValueType, MeanType >::CountType

Type for counting how many times the probe has been started and stopped.

Definition at line 49 of file itkResourceProbe.h.

Constructor & Destructor Documentation

template<typename ValueType, typename MeanType>
itk::ResourceProbe< ValueType, MeanType >::ResourceProbe ( const std::string &  type,
const std::string &  unit 
)

Constructor

template<typename ValueType, typename MeanType>
virtual itk::ResourceProbe< ValueType, MeanType >::~ResourceProbe ( )
virtual

Destructor

Member Function Documentation

template<typename ValueType, typename MeanType>
virtual void itk::ResourceProbe< ValueType, MeanType >::ExpandedReport ( std::ostream &  os = std::cout,
bool  printSystemInfo = true,
bool  printReportHead = true 
)
virtual

Print Probe Results.

template<typename ValueType, typename MeanType>
virtual ValueType itk::ResourceProbe< ValueType, MeanType >::GetInstantValue ( void  ) const
pure virtual

Returns the instant value of the probed system.

Implemented in itk::TimeProbe, and itk::MemoryProbe.

template<typename ValueType, typename MeanType>
virtual ValueType itk::ResourceProbe< ValueType, MeanType >::GetMaximum ( ) const
virtual

Returns the max value changes between the starts and stops of the probe

template<typename ValueType, typename MeanType>
virtual MeanType itk::ResourceProbe< ValueType, MeanType >::GetMean ( ) const
virtual

Returns the average value changes between the starts and stops of the probe. Stop() has to be called at least once, returns 0 otherwise.

template<typename ValueType, typename MeanType>
virtual ValueType itk::ResourceProbe< ValueType, MeanType >::GetMinimum ( ) const
virtual

Returns the min value changes between the starts and stops of the probe

template<typename ValueType, typename MeanType>
virtual std::string itk::ResourceProbe< ValueType, MeanType >::GetNameOfProbe ( ) const
virtual

Set name of probe

template<typename ValueType, typename MeanType>
CountType itk::ResourceProbe< ValueType, MeanType >::GetNumberOfIteration ( ) const

Returns the number of iteration of the probe

template<typename ValueType, typename MeanType>
CountType itk::ResourceProbe< ValueType, MeanType >::GetNumberOfStarts ( ) const

Returns the number of times that the probe has been started

template<typename ValueType, typename MeanType>
CountType itk::ResourceProbe< ValueType, MeanType >::GetNumberOfStops ( ) const

Returns the number of times that the probe has been stopped

template<typename ValueType, typename MeanType>
virtual ValueType itk::ResourceProbe< ValueType, MeanType >::GetStandardDeviation ( )
virtual

Returns the standard deviation value changes between the starts and stops of the probe.

template<typename ValueType, typename MeanType>
virtual void itk::ResourceProbe< ValueType, MeanType >::GetSystemInformation ( )
protectedvirtual

Get System information

template<typename ValueType, typename MeanType>
virtual ValueType itk::ResourceProbe< ValueType, MeanType >::GetTotal ( ) const
virtual

Returns the accumulated value changes between the starts and stops of the probe

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::GetType ( ) const

Returns the type probed value

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::GetUnit ( ) const

Returns the unit probed value

template<typename ValueType, typename MeanType>
virtual void itk::ResourceProbe< ValueType, MeanType >::PrintExpandedReportHead ( std::ostream &  os = std::cout)
protectedvirtual

Print Probe Results.

template<typename ValueType, typename MeanType>
virtual void itk::ResourceProbe< ValueType, MeanType >::PrintReportHead ( std::ostream &  os = std::cout)
protectedvirtual

Print Probe Results.

template<typename ValueType, typename MeanType>
virtual void itk::ResourceProbe< ValueType, MeanType >::PrintSystemInformation ( std::ostream &  os = std::cout)
virtual

Print System information

template<typename ValueType, typename MeanType>
virtual void itk::ResourceProbe< ValueType, MeanType >::Report ( std::ostream &  os = std::cout,
bool  printSystemInfo = true,
bool  printReportHead = true 
)
virtual

Print Probe Results.

template<typename ValueType, typename MeanType>
virtual void itk::ResourceProbe< ValueType, MeanType >::Reset ( )
virtual

Reset the probe

template<typename ValueType, typename MeanType>
virtual void itk::ResourceProbe< ValueType, MeanType >::SetNameOfProbe ( const char *  nameOfProbe)
virtual

Set name of probe

template<typename ValueType, typename MeanType>
virtual void itk::ResourceProbe< ValueType, MeanType >::Start ( )
virtual

Start counting the change of value

template<typename ValueType, typename MeanType>
virtual void itk::ResourceProbe< ValueType, MeanType >::Stop ( )
virtual

Stop counting the change of value.

If a matching Start() has not been called before, there is no effect.

template<typename ValueType, typename MeanType>
virtual void itk::ResourceProbe< ValueType, MeanType >::UpdateMinimumMaximumMeasuredValue ( ValueType  value)
protectedvirtual

Update the Min and Max values with an input value

Member Data Documentation

template<typename ValueType, typename MeanType>
vcl_size_t itk::ResourceProbe< ValueType, MeanType >::m_AvailablePhysicalMemory
private

Definition at line 177 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
vcl_size_t itk::ResourceProbe< ValueType, MeanType >::m_AvailableVirtualMemory
private

Definition at line 175 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
bool itk::ResourceProbe< ValueType, MeanType >::m_Is64Bits
private

Definition at line 172 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::m_ITKVersion
private

Definition at line 173 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
ValueType itk::ResourceProbe< ValueType, MeanType >::m_MaximumValue
private

Definition at line 147 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
MeanType itk::ResourceProbe< ValueType, MeanType >::m_MeanValue
private

Definition at line 148 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
ValueType itk::ResourceProbe< ValueType, MeanType >::m_MinimumValue
private

Definition at line 146 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::m_NameOfProbe
private

Definition at line 157 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
unsigned int itk::ResourceProbe< ValueType, MeanType >::m_NumberOfAvailableCore
private

Definition at line 167 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
CountType itk::ResourceProbe< ValueType, MeanType >::m_NumberOfIteration
private

Definition at line 153 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
unsigned int itk::ResourceProbe< ValueType, MeanType >::m_NumberOfLogicalCPU
private

Definition at line 166 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
unsigned int itk::ResourceProbe< ValueType, MeanType >::m_NumberOfPhysicalCPU
private

Definition at line 165 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
CountType itk::ResourceProbe< ValueType, MeanType >::m_NumberOfStarts
private

Definition at line 151 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
CountType itk::ResourceProbe< ValueType, MeanType >::m_NumberOfStops
private

Definition at line 152 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::m_OSName
private

Definition at line 168 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::m_OSPlatform
private

Definition at line 171 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::m_OSRelease
private

Definition at line 169 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::m_OSVersion
private

Definition at line 170 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
std::vector<ValueType> itk::ResourceProbe< ValueType, MeanType >::m_ProbeValueList
private

Definition at line 155 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
int itk::ResourceProbe< ValueType, MeanType >::m_ProcessorCacheSize
private

Definition at line 163 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
float itk::ResourceProbe< ValueType, MeanType >::m_ProcessorClockFrequency
private

Definition at line 164 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::m_ProcessorName
private

Definition at line 162 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
ValueType itk::ResourceProbe< ValueType, MeanType >::m_StandardDeviation
private

Definition at line 149 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
ValueType itk::ResourceProbe< ValueType, MeanType >::m_StartValue
private

Definition at line 144 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::m_SystemName
private

Definition at line 161 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
vcl_size_t itk::ResourceProbe< ValueType, MeanType >::m_TotalPhysicalMemory
private

Definition at line 176 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
ValueType itk::ResourceProbe< ValueType, MeanType >::m_TotalValue
private

Definition at line 145 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
vcl_size_t itk::ResourceProbe< ValueType, MeanType >::m_TotalVirtualMemory
private

Definition at line 174 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::m_TypeString
private

Definition at line 158 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
std::string itk::ResourceProbe< ValueType, MeanType >::m_UnitString
private

Definition at line 159 of file itkResourceProbe.h.

template<typename ValueType, typename MeanType>
const unsigned int itk::ResourceProbe< ValueType, MeanType >::tabwidth = 15
staticprivate

Definition at line 179 of file itkResourceProbe.h.


The documentation for this class was generated from the following file: