minimc 0.5.1
Loading...
Searching...
No Matches
Estimator Class Referenceabstract

Contains scores, multipliers, and sensitivities for a quantity of interest. More...

#include <Estimator.hpp>

Inheritance diagram for Estimator:
Collaboration diagram for Estimator:

Public Member Functions

 Estimator (const Estimator &other) noexcept
 Copy constructor. Deep copies Scores and each Sensitivity object.
 
virtual ~Estimator () noexcept
 Virtual destructor (C++ Core Guidelines C.127)
 
virtual std::unique_ptr< EstimatorClone () const noexcept=0
 Virtual constructor, used for deep copying an Estimator. More...
 
std::string to_string (const Real total_weight) const noexcept override
 Returns a string suitable for printing. More...
 
Estimatoroperator+= (const Estimator &other) noexcept
 Add scores of other to this including any Sensitivity objects.
 
- Public Member Functions inherited from Scorable
 Scorable (const std::string &name, const pugi::xml_node &bins_node) noexcept
 Constructs a Scorable from a bins node of an XML document. More...
 
 Scorable (const Scorable &estimator, const Perturbation &perturbation) noexcept
 Constructs an Scorable from an existing estimator and perturbation. More...
 
virtual ~Scorable () noexcept
 Virtual destructor (C++ Core Guidelines C.127)
 
virtual Real GetScore (const Particle &p) const noexcept=0
 Returns what a Particle would score. More...
 
virtual std::string to_string (const Real total_weight) const noexcept=0
 Returns a string suitable for printing. More...
 
Real GetScore (const size_t index, const Real total_weight) const noexcept
 Returns all scores; primarily for unit testing.
 
Scorableoperator+= (const Scorable &other) noexcept
 Add scores of other to this.
 

Static Public Member Functions

static std::unique_ptr< EstimatorCreate (const pugi::xml_node &estimator_node, const World &world, const PerturbationSet &perturbations)
 Factory method to create new Estimator from an estimator node of an XML document.
 

Protected Member Functions

 Estimator (const pugi::xml_node &estimator_node, const PerturbationSet &perturbations) noexcept
 Constructs an Estimator from an XML node.
 
- Protected Member Functions inherited from Scorable
std::string GetScoreAsString (const Real total_weight) const noexcept
 Returns a string suitable for printing. More...
 

Additional Inherited Members

- Public Attributes inherited from Scorable
const std::string name
 Unique, user-defined identifier (C++ Core Guidelines C.131)
 
- Protected Attributes inherited from Scorable
const std::shared_ptr< const ParticleBinsbins
 Used to map a Particle to a unique index.
 
std::vector< Realscores
 Flattened array of scores.
 
std::vector< Realsquare_scores
 Flattened array of square of scores.
 

Detailed Description

Contains scores, multipliers, and sensitivities for a quantity of interest.

Member Function Documentation

◆ Clone()

virtual std::unique_ptr< Estimator > Estimator::Clone ( ) const
pure virtualnoexcept

Virtual constructor, used for deep copying an Estimator.

Implemented in CurrentEstimator.

◆ to_string()

std::string Estimator::to_string ( const Real  total_weight) const
overridevirtualnoexcept

Returns a string suitable for printing.

Implements Scorable.


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