HDK
|
This class computes statistics (minimum value, maximum value, mean, variance and standard deviation) of a population of floating-point values. More...
#include <GridStats.h>
Public Types | |
using | ValueType = ValueT |
Public Member Functions | |
__hostdev__ | Stats () |
__hostdev__ Stats & | add (const ValueT &val) |
Add a single sample. More... | |
__hostdev__ Stats & | add (const ValueT &val, uint64_t n) |
Add n samples with constant value val. More... | |
__hostdev__ Stats & | add (const Stats &other) |
Add the samples from the other Stats instance. More... | |
__hostdev__ size_t | size () const |
template<typename NodeT > | |
__hostdev__ void | setStats (NodeT &node) const |
__hostdev__ double | avg () const |
Return the arithmetic mean, i.e. average, value. More... | |
__hostdev__ double | mean () const |
Return the arithmetic mean, i.e. average, value. More... | |
__hostdev__ double | var () const |
Return the population variance. More... | |
__hostdev__ double | variance () const |
Return the population variance. More... | |
__hostdev__ double | std () const |
Return the standard deviation (=Sqrt(variance)) as defined from the (biased) population variance. More... | |
__hostdev__ double | stdDev () const |
Return the standard deviation (=Sqrt(variance)) as defined from the (biased) population variance. More... | |
Static Public Member Functions | |
static __hostdev__ constexpr bool | hasMinMax () |
static __hostdev__ constexpr bool | hasAverage () |
static __hostdev__ constexpr bool | hasStdDeviation () |
static __hostdev__ constexpr bool | hasStats () |
Protected Types | |
using | BaseT = Extrema< ValueT, 1 > |
using | RealT = double |
Protected Attributes | |
size_t | mSize |
double | mAvg |
double | mAux |
This class computes statistics (minimum value, maximum value, mean, variance and standard deviation) of a population of floating-point values.
variance = Mean[ (X-Mean[X])^2 ] = Mean[X^2] - Mean[X]^2, standard deviation = sqrt(variance)
Definition at line 338 of file GridStats.h.
|
protected |
Definition at line 341 of file GridStats.h.
|
protected |
Definition at line 342 of file GridStats.h.
using nanovdb::Stats< ValueT, 1 >::ValueType = ValueT |
Definition at line 347 of file GridStats.h.
|
inline |
Definition at line 348 of file GridStats.h.
|
inline |
Add a single sample.
Definition at line 356 of file GridStats.h.
|
inline |
Add n samples with constant value val.
Definition at line 367 of file GridStats.h.
|
inline |
Add the samples from the other Stats instance.
Definition at line 380 of file GridStats.h.
|
inline |
Return the arithmetic mean, i.e. average, value.
Definition at line 402 of file GridStats.h.
|
inlinestatic |
Definition at line 394 of file GridStats.h.
|
inlinestatic |
Definition at line 393 of file GridStats.h.
|
inlinestatic |
Definition at line 396 of file GridStats.h.
|
inlinestatic |
Definition at line 395 of file GridStats.h.
|
inline |
Return the arithmetic mean, i.e. average, value.
Definition at line 403 of file GridStats.h.
|
inline |
Definition at line 422 of file GridStats.h.
|
inline |
Definition at line 398 of file GridStats.h.
|
inline |
Return the standard deviation (=Sqrt(variance)) as defined from the (biased) population variance.
Definition at line 417 of file GridStats.h.
|
inline |
Return the standard deviation (=Sqrt(variance)) as defined from the (biased) population variance.
Definition at line 418 of file GridStats.h.
|
inline |
Return the population variance.
Definition at line 410 of file GridStats.h.
|
inline |
Return the population variance.
Definition at line 411 of file GridStats.h.
|
protected |
Definition at line 344 of file GridStats.h.
|
protected |
Definition at line 344 of file GridStats.h.
|
protected |
Definition at line 343 of file GridStats.h.