|
OPAL (Object Oriented Parallel Accelerator Library) 2024.2
OPAL
|
#include <Uniform.h>
Public Types | |
| typedef std::conditional< std::is_integral< T >::value, std::uniform_int_distribution< T >, std::uniform_real_distribution< T > >::type | dist_t |
Public Member Functions | |
| Uniform (T lower, T upper) | |
| Uniform (T lower, T upper, std::size_t seed) | |
| ~Uniform () | |
| void | create (std::shared_ptr< SampleIndividual > &ind, size_t i) |
| void | allocate (const CmdArguments_t &, const Comm::Bundle_t &comm) |
| T | getNext () |
Private Attributes | |
| dist_t | dist_m |
| RNGStream * | RNGInstance_m |
| std::size_t | seed_m |
|
inline |
Definition at line 40 of file Uniform.h.
References dist_m, RNGInstance_m, and seed_m.
|
inline |
Definition at line 46 of file Uniform.h.
References dist_m, RNGInstance_m, and seed_m.
Definition at line 52 of file Uniform.h.
References RNGStream::deleteInstance(), and RNGInstance_m.
|
inlinevirtual |
Allocate memory for sampling. Not every sampling method requires that.
This function is used to reduce memory since only the sampler ranks need these sampling methods.
| args | samler arguments |
| comm | sampler communicator |
Reimplemented from SamplingMethod.
Definition at line 61 of file Uniform.h.
References RNGStream::getInstance(), Comm::Bundle_t::island_id, RNGInstance_m, and seed_m.
|
inlinevirtual |
Implements SamplingMethod.
Definition at line 57 of file Uniform.h.
References dist_m, and RNGInstance_m.
|
inline |
Definition at line 66 of file Uniform.h.
References dist_m, and RNGInstance_m.
Definition at line 73 of file Uniform.h.
Referenced by allocate(), create(), getNext(), Uniform(), Uniform(), and ~Uniform().
|
private |
Definition at line 75 of file Uniform.h.
Referenced by allocate(), Uniform(), and Uniform().