vSMC
vSMC: Scalable Monte Carlo
Classes | Typedefs | Functions
Resampling algorithms

Resampling algorithm functor classes. More...

Classes

class  vsmc::ResampleIndex< IntType >
 Record and trace resample index. More...
 
class  vsmc::ResampleMultinomial
 Multinomial resampling. More...
 
class  vsmc::ResampleResidual
 Residual resampling. More...
 
class  vsmc::ResampleResidualStratified
 Residual stratified resampling. More...
 
class  vsmc::ResampleResidualSystematic
 Residual systematic resampling. More...
 
class  vsmc::ResampleStratified
 Stratified resampling. More...
 
class  vsmc::ResampleSystematic
 Systematic resampling. More...
 
class  vsmc::ResampleTypeTrait< ResampleScheme >
 Type trait of ResampleScheme parameter. More...
 
class  vsmc::ResampleTypeTrait< Multinomial >
 Type trait of Multinomial scheme. More...
 
class  vsmc::ResampleTypeTrait< Residual >
 Type trait of Residual scheme. More...
 
class  vsmc::ResampleTypeTrait< ResidualStratified >
 Type trait of ResidualStratified scheme. More...
 
class  vsmc::ResampleTypeTrait< ResidualSystematic >
 Type trait of ResidualSystematic scheme. More...
 
class  vsmc::ResampleTypeTrait< Stratified >
 Type trait of Stratified scheme. More...
 
class  vsmc::ResampleTypeTrait< Systematic >
 Type trait of Systematic scheme. More...
 

Typedefs

template<ResampleScheme Scheme>
using vsmc::ResampleType = typename ResampleTypeTrait< Scheme >::type
 Type of resample class corresponding to ResampleScheme parameter. More...
 

Functions

template<typename IntType1 , typename IntType2 >
void vsmc::resample_trans_index_rep (std::size_t M, std::size_t N, const IntType1 *src_idx, IntType2 *replication)
 Transform parent indices into replication numbers. More...
 
template<typename IntType1 , typename IntType2 >
void vsmc::resample_trans_rep_index (std::size_t M, std::size_t N, const IntType1 *replication, IntType2 *src_idx)
 Transform replication numbers into parent indices. More...
 
template<typename IntType >
std::size_t vsmc::resample_trans_residual (std::size_t M, std::size_t N, const double *weight, double *resid, IntType *integ)
 Transform normalized weights to normalized residual and integrals, and return the number of remaining elements to be resampled. More...
 
template<typename IntType , typename U01SeqType >
void vsmc::resample_trans_u01_index (std::size_t M, std::size_t N, const double *weight, U01SeqType &&u01seq, IntType *src_idx)
 Transform uniform [0, 1] sequence into parent indices. More...
 
template<typename IntType , typename U01SeqType >
void vsmc::resample_trans_u01_rep (std::size_t M, std::size_t N, const double *weight, U01SeqType &&u01seq, IntType *replication)
 Transform uniform [0, 1] sequence into replication numbers. More...
 

Detailed Description

Resampling algorithm functor classes.

Typedef Documentation

template<ResampleScheme Scheme>
using vsmc::ResampleType = typedef typename ResampleTypeTrait<Scheme>::type

Type of resample class corresponding to ResampleScheme parameter.

Definition at line 61 of file common.hpp.

Function Documentation

template<typename IntType1 , typename IntType2 >
void vsmc::resample_trans_index_rep ( std::size_t  M,
std::size_t  N,
const IntType1 *  src_idx,
IntType2 *  replication 
)
inline

Transform parent indices into replication numbers.

Definition at line 139 of file transform.hpp.

template<typename IntType1 , typename IntType2 >
void vsmc::resample_trans_rep_index ( std::size_t  M,
std::size_t  N,
const IntType1 *  replication,
IntType2 *  src_idx 
)
inline

Transform replication numbers into parent indices.

Definition at line 100 of file transform.hpp.

template<typename IntType >
std::size_t vsmc::resample_trans_residual ( std::size_t  M,
std::size_t  N,
const double *  weight,
double *  resid,
IntType *  integ 
)
inline

Transform normalized weights to normalized residual and integrals, and return the number of remaining elements to be resampled.

Definition at line 155 of file transform.hpp.

template<typename IntType , typename U01SeqType >
void vsmc::resample_trans_u01_index ( std::size_t  M,
std::size_t  N,
const double *  weight,
U01SeqType &&  u01seq,
IntType *  src_idx 
)
inline

Transform uniform [0, 1] sequence into parent indices.

Definition at line 76 of file transform.hpp.

template<typename IntType , typename U01SeqType >
void vsmc::resample_trans_u01_rep ( std::size_t  M,
std::size_t  N,
const double *  weight,
U01SeqType &&  u01seq,
IntType *  replication 
)
inline

Transform uniform [0, 1] sequence into replication numbers.

Definition at line 43 of file transform.hpp.