firecrown.likelihood.gauss_family.statistic.statistic.Statistic#
- class firecrown.likelihood.gauss_family.statistic.statistic.Statistic(parameter_prefix=None)[source]#
Bases:
UpdatableThe abstract base class for all physics-related statistics.
Statistics read data from a SACC object as part of a multi-phase initialization. They manage a
DataVectorand, given aModelingToolsobject, can compute aTheoryVector.Statistics represent things like two-point functions and mass functions.
- Parameters:
parameter_prefix (
Optional[str]) –
Public Methods:
__init__([parameter_prefix])Updatable initialization.
read(_)Read the data for this statistic and mark it as ready for use.
get_data_vector()Gets the statistic data vector.
compute_theory_vector(tools)Compute a statistic from sources, applying any systematics.
get_theory_vector()Returns the last computed theory vector.
Inherited from
Updatable__init__([parameter_prefix])Updatable initialization.
__setattr__(key, value)Set the attribute named
keyto the supplied value.set_parameter(key, value)Sets the parameter to the given value.
set_internal_parameter(key, value)Assure this InternalParameter has not already been set, and then set it.
set_sampler_parameter(key, value)Assure this SamplerParameter has not already been set, and then set it.
update(params)Update self by calling to prepare for the next MCMC sample.
is_updated()Determine if the object has been updated.
reset()Reset the updatable.
required_parameters()Returns a RequiredParameters object.
get_derived_parameters()Returns a collection of derived parameters.
Private Methods:
_reset()Reset this statistic.
_compute_theory_vector(tools)Compute a statistic from sources, concrete implementation.
Inherited from
Updatable_update(params)Method for auxiliary updates to be made to an updatable.
_reset()Abstract method implemented by all concrete classes to update self.
_required_parameters()Return a RequiredParameters object containing the information for this class.
_get_derived_parameters()Returns the derived parameters of an implementation.
- abstract _compute_theory_vector(tools)[source]#
Compute a statistic from sources, concrete implementation.
- Parameters:
tools (
ModelingTools) –- Return type:
- final compute_theory_vector(tools)[source]#
Compute a statistic from sources, applying any systematics.
- Parameters:
tools (
ModelingTools) –- Return type:
- get_theory_vector()[source]#
Returns the last computed theory vector.
Raises a RuntimeError if the vector has not been computed.
- Return type:
- read(_)[source]#
Read the data for this statistic and mark it as ready for use.
Derived classes that override this function should make sure to call the base class method using:
super().read(sacc_data)
as the last thing they do in __init__.
Note that currently the argument is not used; it is present so that this method will have the correct argument type for the override.
- Parameters:
_ (
Sacc) –- Return type:
None