Hyperiso 1.0.3
Modular flavour-physics calculations, Wilson coefficients and statistical inference
Loading...
Searching...
No Matches
ContourEngine.h
Go to the documentation of this file.
1#ifndef CONTOURENGINE_H
2#define CONTOURENGINE_H
3
4#include <chrono>
5
6#include "ILikelihood.h"
8#include "IContourExtractor.h"
10#include "Profiler.h"
11#include "JointDistribution.h"
13#include "WithFallback.h"
14#include "AMSContourExtractor.h"
15#include "MnContourExtractor.h"
16#include "GaussianMarginal.h"
17#include "GaussianCopula.h"
18#include "ContourObserver.h"
19#include "Profiler.h"
20
44
45
50enum class ContourAlgorithm {
51 AMS,
52 MINUIT
53};
54
69
81public:
93 ContourEngine(std::shared_ptr<ILikelihood> base, const ContourConfig& cfg);
94
107 Contour compute_contour(double z, std::array<double, 4> bounds, std::size_t resolution);
108
109private:
118 std::shared_ptr<JointDistribution> build_constraints_distribution();
119
128 std::shared_ptr<IContourExtractor> build_contour_extractor(ContourAlgorithm ca);
129
130 ContourConfig cfg;
131 ProfiledLikelihood2D likelihood;
132 std::shared_ptr<IContourExtractor> extractor;
133};
134
135#endif // CONTOURENGINE_H
Adaptive marching-squares contour extractor.
ContourAlgorithm
Algorithm family used to extract contour paths from the profiled field.
@ AMS
Adaptive/marching-squares contour extractor.
@ MINUIT
Minuit contour extractor.
ProfilingMethod
Strategy used to reduce the full likelihood to a 2D profile.
@ SLICE
Fix all fit parameters except nuisances; scan only the selected axes.
@ FREE_PROJECTION
Fix selected axes and profile all remaining parameters.
@ PRIOR_CONSTRAINED_PROJECTION
Profile remaining parameters with Gaussian constraints around the fit result.
Progress-event types and callback interface for contour extraction.
std::function< void(const ContourProgressEvent &)> ContourProgressCallback
Callback signature used to receive contour progress events.
Gaussian copula implementation.
Common data structures and interface for 2D contour extraction.
Abstract interface for likelihood functions used by the fitting layer.
Profiling strategies used to build two-dimensional likelihood scan requests.
Joint probability distribution built from marginals and a copula.
Minuit-backed implementation of the contour extraction interface.
Two-dimensional profiled likelihood wrapper.
Generic likelihood profiling engine.
ProfilerMode
Available algorithms for profiling free parameters.
Definition Profiler.h:25
Decorator adding fallback behavior to contour extraction.
Likelihood decorator adding an external Gaussian constraint term.
Orchestrates profiled likelihood contour computation.
Contour compute_contour(double z, std::array< double, 4 > bounds, std::size_t resolution)
Computes a profiled 2D contour for a requested significance.
Evaluates a profiled NLL as a function of two scan coordinates.
Configuration object for ContourEngine.
ProfilerMode profile_backend
Backend used to profile nuisance/free parameters.
ProfilingMethod profiling_method
Profiling strategy used for non-displayed parameters.
ContourProgressCallback on_progress
Optional progress callback invoked during contour computation.
std::size_t x_id
std::size_t y_id
Indices of the two fit parameters displayed on the contour axes.
std::optional< ContourAlgorithm > fallback_contour_method
Optional fallback algorithm if the primary fails.
ContourAlgorithm primary_contour_method
Primary contour extraction algorithm.
FitResult fr
Global fit result used for central values, uncertainties, and correlations.
Output of a contour extraction algorithm.
Summary of a global likelihood fit.