OpenNN  2.2
Open Neural Networks Library
Public Member Functions | Public Attributes | List of all members
OpenNN::Histogram< T > Struct Template Reference

#include <vector.h>

Public Member Functions

 Histogram (void)
 
virtual ~Histogram (void)
 
 Histogram (const size_t &)
 
 Histogram (const Vector< T > &, const Vector< size_t > &)
 
size_t get_bins_number (void) const
 
size_t count_empty_bins (void) const
 
size_t calculate_minimum_frequency (void) const
 
size_t calculate_maximum_frequency (void) const
 
size_t calculate_most_populated_bin (void) const
 
Vector< T > calculate_minimal_centers (void) const
 
Vector< T > calculate_maximal_centers (void) const
 
size_t calculate_bin (const T &) const
 
size_t calculate_frequency (const T &) const
 

Public Attributes

Vector< T > centers
 
Vector< T > minimums
 
Vector< T > maximums
 
Vector< size_t > frequencies
 

Detailed Description

template<class T>
struct OpenNN::Histogram< T >

This template contains the data needed to represent a histogram.

Definition at line 56 of file vector.h.

Constructor & Destructor Documentation

◆ Histogram() [1/2]

template<class T >
OpenNN::Histogram< T >::Histogram ( const size_t &  bins_number)

Bins number constructor.

Bins number constructor.

Parameters
bins_numberNumber of bins in the histogram.

Definition at line 6538 of file vector.h.

◆ Histogram() [2/2]

template<class T >
OpenNN::Histogram< T >::Histogram ( const Vector< T > &  new_centers,
const Vector< size_t > &  new_frequencies 
)

Values constructor.

Values constructor.

Parameters
new_centersCenter values for the bins.
new_frequenciesNumber of variates in each bin.

Definition at line 6548 of file vector.h.

Member Function Documentation

◆ calculate_bin()

template<class T >
size_t OpenNN::Histogram< T >::calculate_bin ( const T &  value) const

Returns the number of the bin to which a given value belongs to.

Parameters
valueValue for which we want to get the bin.

Definition at line 6618 of file vector.h.

◆ calculate_frequency()

template<class T >
size_t OpenNN::Histogram< T >::calculate_frequency ( const T &  value) const

Returns the frequency of the bin to which a given value bolongs to.

Parameters
valueValue for which we want to get the frequency.

Definition at line 6662 of file vector.h.


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