AmpGen
2.1
Toggle main menu visibility
Loading...
Searching...
No Matches
Chi2Estimator.h
Go to the documentation of this file.
1
#ifndef AMPGEN_CHI2ESTIMATOR_H
2
#define AMPGEN_CHI2ESTIMATOR_H
3
4
#include <functional>
5
#include <string>
6
#include <vector>
7
8
#include "
AmpGen/BinDT.h
"
9
10
#if ENABLE_AVX
11
#include "
AmpGen/EventListSIMD.h
"
12
#else
13
#include "
AmpGen/EventList.h
"
14
#endif
15
16
namespace
AmpGen
{
17
class
EventType
;
18
class
Event
;
19
20
class
Chi2Estimator
{
21
#if ENABLE_AVX
22
typedef
EventListSIMD
EventList_type;
23
#else
24
typedef
EventList
EventList_type;
25
#endif
26
public
:
27
template
<
typename
... argument_types>
28
Chi2Estimator
(
const
EventList_type &dataEvents,
const
EventList_type &mcEvents,
const
std::function<
double
(
const
Event
&)> &
fcn
,
29
const
argument_types &...args)
30
: m_binning(dataEvents.begin(), dataEvents.end(),
ArgumentPack
(args...)) {
31
doChi2
(dataEvents, mcEvents,
fcn
);
32
}
33
34
double
chi2
()
const
;
35
double
nBins
()
const
;
36
void
writeBinningToFile
(
const
std::string &filename);
37
void
doChi2
(
const
EventList_type &dataEvents,
const
EventList_type &mcEvents,
const
std::function<
double
(
const
Event
&)> &
fcn
);
38
39
private
:
40
double
m_chi2;
41
size_t
m_nBins;
42
BinDT
m_binning;
43
};
44
}
// namespace AmpGen
45
46
#endif
/* end of include guard: AMPGEN_CHI2ESTIMATOR_H */
BinDT.h
EventList.h
EventListSIMD.h
AmpGen::ArgumentPack
Container for a set of arguments Contains a set of arguments packed from a variadic constructor,...
Definition
ArgumentPack.h:65
AmpGen::BinDT
Definition
BinDT.h:31
AmpGen::Chi2Estimator::Chi2Estimator
Chi2Estimator(const EventList_type &dataEvents, const EventList_type &mcEvents, const std::function< double(const Event &)> &fcn, const argument_types &...args)
Definition
Chi2Estimator.h:28
AmpGen::Chi2Estimator::nBins
double nBins() const
AmpGen::Chi2Estimator::chi2
double chi2() const
AmpGen::Chi2Estimator::doChi2
void doChi2(const EventList_type &dataEvents, const EventList_type &mcEvents, const std::function< double(const Event &)> &fcn)
AmpGen::Chi2Estimator::writeBinningToFile
void writeBinningToFile(const std::string &filename)
AmpGen::Event
Encapsulates the final state particles of a single event.
Definition
Event.h:19
AmpGen::EventList
Definition
EventList.h:32
AmpGen::EventListSIMD
Definition
EventListSIMD.h:32
AmpGen::EventType
Deals with final state configuration of events, specifically dealing with the ordering of particles i...
Definition
EventType.h:22
AmpGen::fcn
Definition
Expression.h:464
AmpGen
Definition
AddCPConjugate.h:2
AmpGen
Chi2Estimator.h
Generated on
for AmpGen by
1.17.0