ATLAS Offline Software
DataTweaker.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
10 #ifndef LArSamples_DataTweaker_H
11 #define LArSamples_DataTweaker_H
12 
13 
14 #include "LArSamplesMon/Chi2Calc.h"
16 #include <map>
17 
18 namespace LArSamples {
19 
20  class Data;
21  class EventData;
22  class ScaledErrorData;
23 
25 
26  public:
27 
28  DataTweaker() = default;
29 
30  bool set(const TString& tweaks);
31  bool findOption(TString& tweaks, const TString& option) const;
32 
33  Data* tweak(const Data& data, int evtIndex = -1) const;
34  EventData* tweak(const EventData& eventData, int runIndex = -1) const;
35 
36  void setNSamplesTrunctation(unsigned int n) { m_nSamplesTruncation = n; }
37  void addSample(unsigned int n) { m_samples[n] = true; }
38  void setRemoveNoiseCorrelations(bool remove = true) { m_removeNoiseCorrelations = remove; }
39  void setRefit(bool refit = true) { m_refit = refit; }
40  void setFitParams(Chi2Params params) { m_fitParams = params; }
41  void setAdjust(bool adjust = true) { m_adjust = adjust; }
42  void setRemoveRoIs(bool removeRoIs = true) { m_removeRoIs = removeRoIs; }
43 
44  private:
45 
46  unsigned int m_nSamplesTruncation{0};
47  bool m_removeNoiseCorrelations{false}, m_refit{false}, m_adjust{false}, m_removeRoIs{false};
48  std::map<unsigned int, bool> m_samples; //automatically ordered...
49  Chi2Params m_fitParams{DefaultChi2};
50  };
51 }
52 #endif
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
Chi2Calc.h
WriteBchToCool.adjust
adjust
Definition: WriteBchToCool.py:73
LArSamples::DataTweaker::setRefit
void setRefit(bool refit=true)
Definition: DataTweaker.h:39
ATLAS_NOT_THREAD_SAFE
#define ATLAS_NOT_THREAD_SAFE
getNoisyStrip() Find noisy strips from hitmaps and write out into xml/db formats
Definition: checker_macros.h:212
LArSamples::DataTweaker::setAdjust
void setAdjust(bool adjust=true)
Definition: DataTweaker.h:41
Data
@ Data
Definition: BaseObject.h:11
LArSamples
Definition: AbsShape.h:24
ScaledErrorData
Liquid Argon class for standalone storage of cell shape information.
LArSamples::Chi2Params
Chi2Params
Definition: Chi2Calc.h:24
PixelModuleFeMask_create_db.remove
string remove
Definition: PixelModuleFeMask_create_db.py:83
LArSamples::DataTweaker::DataTweaker
DataTweaker()=default
beamspotman.n
n
Definition: beamspotman.py:731
LArSamples::DataTweaker::setRemoveNoiseCorrelations
void setRemoveNoiseCorrelations(bool remove=true)
Definition: DataTweaker.h:38
EventData
Definition: Trigger/TrigAccel/TrigCudaFitter/src/EventData.h:11
LArSamples::DataTweaker
Definition: DataTweaker.h:24
LArSamples::DataTweaker::setRemoveRoIs
void setRemoveRoIs(bool removeRoIs=true)
Definition: DataTweaker.h:42
LArSamples::DataTweaker::setNSamplesTrunctation
void setNSamplesTrunctation(unsigned int n)
Definition: DataTweaker.h:36
CxxUtils::set
constexpr std::enable_if_t< is_bitmask_v< E >, E & > set(E &lhs, E rhs)
Convenience function to set bits in a class enum bitmask.
Definition: bitmask.h:232
LArSamples::DataTweaker::setFitParams
void setFitParams(Chi2Params params)
Definition: DataTweaker.h:40
LArSamples::Data
Definition: Data.h:72
LArSamples::DataTweaker::m_samples
std::map< unsigned int, bool > m_samples
Definition: DataTweaker.h:48
LArSamples::DefaultChi2
@ DefaultChi2
Definition: Chi2Calc.h:24
LArSamples::DataTweaker::addSample
void addSample(unsigned int n)
Definition: DataTweaker.h:37
PowhegControl_ttFCNC_NLO.params
params
Definition: PowhegControl_ttFCNC_NLO.py:226
checker_macros.h
Define macros for attributes used to control the static checker.
LArSamples::EventData
Definition: LArCalorimeter/LArCafJobs/LArCafJobs/EventData.h:29