Brush C++ API
A flexible interpretable machine learning framework
Loading...
Searching...
No Matches
Brush::Util::Timer Class Reference

class for timing things. More...

#include <utils.h>

Public Member Functions

 Timer (bool run=false)
 
void Reset ()
 
std::chrono::duration< floatElapsed () const
 

Private Types

typedef std::chrono::high_resolution_clock high_resolution_clock
 
typedef std::chrono::seconds seconds
 

Private Attributes

high_resolution_clock::time_point _start
 

Friends

template<typename T , typename Traits >
std::basic_ostream< T, Traits > & operator<< (std::basic_ostream< T, Traits > &out, const Timer &timer)
 

Detailed Description

class for timing things.

Definition at line 269 of file utils.h.

Member Typedef Documentation

◆ high_resolution_clock

typedef std::chrono::high_resolution_clock Brush::Util::Timer::high_resolution_clock
private

Definition at line 271 of file utils.h.

◆ seconds

typedef std::chrono::seconds Brush::Util::Timer::seconds
private

Definition at line 273 of file utils.h.

Constructor & Destructor Documentation

◆ Timer()

Brush::Util::Timer::Timer ( bool run = false)
explicit

Definition at line 85 of file utils.cpp.

Here is the call graph for this function:

Member Function Documentation

◆ Elapsed()

std::chrono::duration< float > Brush::Util::Timer::Elapsed ( ) const

Definition at line 94 of file utils.cpp.

◆ Reset()

void Brush::Util::Timer::Reset ( )

Definition at line 90 of file utils.cpp.

Here is the caller graph for this function:

Friends And Related Symbol Documentation

◆ operator<<

template<typename T , typename Traits >
std::basic_ostream< T, Traits > & operator<< ( std::basic_ostream< T, Traits > & out,
const Timer & timer )
friend

Definition at line 283 of file utils.h.

Member Data Documentation

◆ _start

high_resolution_clock::time_point Brush::Util::Timer::_start
private

Definition at line 290 of file utils.h.


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