Public Member Functions | List of all members
beluga::actions::detail::reweight_base_fn Struct Reference

Implementation detail for a reweight range adaptor object. More...

#include <reweight.hpp>

Inheritance diagram for beluga::actions::detail::reweight_base_fn:
Inheritance graph
[legend]

Public Member Functions

template<class ExecutionPolicy , class Range , class Model , std::enable_if_t< std::is_execution_policy_v< std::decay_t< ExecutionPolicy >>, int > = 0, std::enable_if_t< ranges::range< Range >, int > = 0>
constexpr auto operator() (ExecutionPolicy &&policy, Range &range, Model model) const -> Range &
 Overload that implements the reweight algorithm. More...
 
template<class ExecutionPolicy , class Model , std::enable_if_t< std::is_execution_policy_v< ExecutionPolicy >, int > = 0>
constexpr auto operator() (ExecutionPolicy policy, Model model) const
 Overload that returns a view closure to compose with other views. More...
 
template<class Range , class Model , class ExecutionPolicy , std::enable_if_t< ranges::range< Range >, int > = 0, std::enable_if_t< std::is_execution_policy_v< ExecutionPolicy >, int > = 0>
constexpr auto operator() (Range &&range, Model model, ExecutionPolicy policy) const -> Range &
 Overload that re-orders arguments from a view closure. More...
 

Detailed Description

Implementation detail for a reweight range adaptor object.

Definition at line 38 of file reweight.hpp.

Member Function Documentation

◆ operator()() [1/3]

template<class ExecutionPolicy , class Range , class Model , std::enable_if_t< std::is_execution_policy_v< std::decay_t< ExecutionPolicy >>, int > = 0, std::enable_if_t< ranges::range< Range >, int > = 0>
constexpr auto beluga::actions::detail::reweight_base_fn::operator() ( ExecutionPolicy &&  policy,
Range &  range,
Model  model 
) const -> Range&
inlineconstexpr

Overload that implements the reweight algorithm.

Template Parameters
ExecutionPolicyAn execution policy.
RangeAn input range of particles.
ModelA callable that can compute the importance weight given a particle state.
Parameters
policyThe execution policy to use.
rangeAn existing range of particles to apply this action to.
modelA callable instance to compute the weights given the particle states.

For each particle, we multiply the current weight by the new importance weight to accumulate information from sensor updates.

Definition at line 57 of file reweight.hpp.

◆ operator()() [2/3]

template<class ExecutionPolicy , class Model , std::enable_if_t< std::is_execution_policy_v< ExecutionPolicy >, int > = 0>
constexpr auto beluga::actions::detail::reweight_base_fn::operator() ( ExecutionPolicy  policy,
Model  model 
) const
inlineconstexpr

Overload that returns a view closure to compose with other views.

Definition at line 84 of file reweight.hpp.

◆ operator()() [3/3]

template<class Range , class Model , class ExecutionPolicy , std::enable_if_t< ranges::range< Range >, int > = 0, std::enable_if_t< std::is_execution_policy_v< ExecutionPolicy >, int > = 0>
constexpr auto beluga::actions::detail::reweight_base_fn::operator() ( Range &&  range,
Model  model,
ExecutionPolicy  policy 
) const -> Range&
inlineconstexpr

Overload that re-orders arguments from a view closure.

Definition at line 78 of file reweight.hpp.


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


beluga
Author(s):
autogenerated on Tue Jul 16 2024 02:59:54