Public Member Functions | Private Attributes | List of all members
gtsam::WeightedSampler< Engine > Class Template Reference

#include <WeightedSampler.h>

Public Member Functions

std::vector< size_tsampleWithoutReplacement (size_t numSamples, const std::vector< double > &weights)
 
 WeightedSampler (Engine *engine)
 

Private Attributes

Engine * engine_
 

Detailed Description

template<class Engine = std::mt19937>
class gtsam::WeightedSampler< Engine >

Definition at line 37 of file WeightedSampler.h.

Constructor & Destructor Documentation

◆ WeightedSampler()

template<class Engine = std::mt19937>
gtsam::WeightedSampler< Engine >::WeightedSampler ( Engine *  engine)
inlineexplicit

Construct from random number generation engine We only store a pointer to it.

Definition at line 46 of file WeightedSampler.h.

Member Function Documentation

◆ sampleWithoutReplacement()

template<class Engine = std::mt19937>
std::vector<size_t> gtsam::WeightedSampler< Engine >::sampleWithoutReplacement ( size_t  numSamples,
const std::vector< double > &  weights 
)
inline

Definition at line 48 of file WeightedSampler.h.

Member Data Documentation

◆ engine_

template<class Engine = std::mt19937>
Engine* gtsam::WeightedSampler< Engine >::engine_
private

Definition at line 39 of file WeightedSampler.h.


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


gtsam
Author(s):
autogenerated on Tue Jul 4 2023 02:47:15