|
ATLAS Offline Software
|
Modified class for shower library generation algorithm.
More...
#include <FastCaloSimParamAlg.h>
|
| FastCaloSimParamAlg (const std::string &name, ISvcLocator *pSvcLocator) |
|
virtual StatusCode | initialize () override final |
|
virtual StatusCode | execute () override final |
|
virtual StatusCode | sysInitialize () override |
| Override sysInitialize. More...
|
|
virtual const DataObjIDColl & | extraOutputDeps () const override |
| Return the list of extra output dependencies. More...
|
|
ServiceHandle< StoreGateSvc > & | evtStore () |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | evtStore () const |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | detStore () const |
| The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
virtual StatusCode | sysStart () override |
| Handle START transition. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | inputHandles () const override |
| Return this algorithm's input handles. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | outputHandles () const override |
| Return this algorithm's output handles. More...
|
|
Gaudi::Details::PropertyBase & | declareProperty (Gaudi::Property< T > &t) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc="none") |
| Declare a new Gaudi property. More...
|
|
void | updateVHKA (Gaudi::Details::PropertyBase &) |
|
MsgStream & | msg () const |
|
MsgStream & | msg (const MSG::Level lvl) const |
|
bool | msgLvl (const MSG::Level lvl) const |
|
Modified class for shower library generation algorithm.
Definition at line 39 of file FastCaloSimParamAlg.h.
◆ StoreGateSvc_t
◆ FastCaloSimParamAlg()
FastCaloSimParamAlg::FastCaloSimParamAlg |
( |
const std::string & |
name, |
|
|
ISvcLocator * |
pSvcLocator |
|
) |
| |
Definition at line 39 of file FastCaloSimParamAlg.cxx.
49 "max distance squared after which the hits will be truncated");
51 "energy border, that truncation won't cross");
53 "maximal radius squared until two hits will be combined");
55 "maximal radius in LAr squared until two hits will be combined");
57 "maximal radius in HEC squared until two hits will be combined");
59 "maximal radius in FCAL squared until two hits will be combined");
61 "maximal radius in Tile squared until two hits will be combined");
71 "energy fraction that will be inside containment borders");
73 "List of files to read library structures from");
75 "the allowed amount of energy that can be deposited outside calorimeter region ");
◆ clusterize()
Definition at line 113 of file FastCaloSimParamAlg.cxx.
115 ATH_MSG_DEBUG(
"Initial clusterize size: "<<stepinfo->
size()<<
" - will merge steps in the same cell which are less than dR and dT to each other");
116 double total_energy1(0.);
117 for (
const auto step: *stepinfo) {
118 total_energy1+=
step->energy();
120 ATH_MSG_DEBUG(
"Check: total energy before clusterize "<<total_energy1);
127 std::map<Identifier, ISF_FCS_Parametrization::FCS_StepInfoCollection*> FCS_SIC_cells;
128 for (
const auto step: *stepinfo) {
129 if (FCS_SIC_cells.find(
step->identify()) != FCS_SIC_cells.end()) {
130 auto&& stepCopy = std::make_unique<ISF_FCS_Parametrization::FCS_StepInfo>(*
step);
131 FCS_SIC_cells[
step->identify()]->push_back( stepCopy.release() );
134 auto && new_fcs_sic = std::make_unique<ISF_FCS_Parametrization::FCS_StepInfoCollection>();
135 auto&& stepCopy = std::make_unique<ISF_FCS_Parametrization::FCS_StepInfo>(*
step);
136 new_fcs_sic->push_back( stepCopy.release() );
137 FCS_SIC_cells.insert(std::pair<Identifier, ISF_FCS_Parametrization::FCS_StepInfoCollection*>(
step->identify(),new_fcs_sic.release()));
141 ATH_MSG_DEBUG(
"Merging separately in each cell: Ncells: "<<FCS_SIC_cells.size());
150 else if ((
it->second)->size()==1) {
178 while (
it1 != (
it->second)->end() ) {
180 while (it2 != (
it->second)->end()) {
181 if (((*it1)->diff2(**it2) < dsame) && std::fabs((*it1)->time() - (*it2)->time()) < tsame ) {
183 it2 = (
it->second)->erase(it2);
195 for (
const auto step: *(
it->second)) {
196 auto&& stepCopy = std::make_unique<ISF_FCS_Parametrization::FCS_StepInfo>(*
step);
197 stepinfo->push_back( stepCopy.release() );
203 double total_energy2(0.);
204 for (
const auto step: *stepinfo) {
205 total_energy2+=
step->energy();
209 unsigned int nInvalid(0);
212 while(stepIter != stepinfo->end()) {
213 if ((*stepIter)->valid()) {
218 stepIter = stepinfo->erase(stepIter);
220 ATH_MSG_DEBUG(
"Removed "<<nInvalid<<
" StepInfo objects. New collection size: "<<stepinfo->size());
221 return StatusCode::SUCCESS;
◆ declareGaudiProperty() [1/4]
specialization for handling Gaudi::Property<SG::VarHandleKeyArray>
Definition at line 170 of file AthCommonDataStore.h.
175 hndl.documentation());
◆ declareGaudiProperty() [2/4]
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition at line 156 of file AthCommonDataStore.h.
161 hndl.documentation());
◆ declareGaudiProperty() [3/4]
specialization for handling Gaudi::Property<SG::VarHandleBase>
Definition at line 184 of file AthCommonDataStore.h.
189 hndl.documentation());
◆ declareGaudiProperty() [4/4]
◆ declareProperty() [1/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleBase
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 245 of file AthCommonDataStore.h.
250 this->declare(hndl.
vhKey());
251 hndl.
vhKey().setOwner(
this);
253 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [2/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleKey
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 221 of file AthCommonDataStore.h.
229 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [3/6]
◆ declareProperty() [4/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This is the generic version, for types that do not derive from SG::VarHandleKey
. It just forwards to the base class version of declareProperty
.
Definition at line 333 of file AthCommonDataStore.h.
338 return PBASE::declareProperty(
name, property,
doc);
◆ declareProperty() [5/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This dispatches to either the generic declareProperty
or the one for VarHandle/Key/KeyArray.
Definition at line 352 of file AthCommonDataStore.h.
◆ declareProperty() [6/6]
◆ detStore()
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ execute()
StatusCode FastCaloSimParamAlg::execute |
( |
| ) |
|
|
finaloverridevirtual |
Definition at line 89 of file FastCaloSimParamAlg.cxx.
93 ATH_CHECK(outputHandle.record(std::make_unique<ISF_FCS_Parametrization::FCS_StepInfoCollection>()));
98 for (
const auto *
const step: *inputHandle ) {
99 auto&& stepCopy = std::make_unique<ISF_FCS_Parametrization::FCS_StepInfo>(*
step);
100 outputHandle->push_back( stepCopy.release() );
110 return StatusCode::SUCCESS;
◆ extraDeps_update_handler()
Add StoreName to extra input/output deps as needed.
use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given
◆ extraOutputDeps()
const DataObjIDColl & AthAlgorithm::extraOutputDeps |
( |
| ) |
const |
|
overridevirtualinherited |
Return the list of extra output dependencies.
This list is extended to include symlinks implied by inheritance relations.
Definition at line 50 of file AthAlgorithm.cxx.
57 return Algorithm::extraOutputDeps();
◆ initialize()
StatusCode FastCaloSimParamAlg::initialize |
( |
| ) |
|
|
finaloverridevirtual |
◆ inputHandles()
Return this algorithm's input handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ outputHandles()
Return this algorithm's output handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ renounce()
◆ renounceArray()
◆ sysInitialize()
StatusCode AthAlgorithm::sysInitialize |
( |
| ) |
|
|
overridevirtualinherited |
◆ sysStart()
Handle START transition.
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.
◆ truncate()
Definition at line 224 of file FastCaloSimParamAlg.cxx.
229 while (stepIter != stepinfo->
end()) {
230 if ((
m_truncate>=2)&&((*stepIter)->time()>1000)) {
231 stepIter = stepinfo->
erase(stepIter);
238 return StatusCode::SUCCESS;
◆ updateVHKA()
◆ m_caloMgrKey
Initial value:{ this
, "CaloDetDescrManager"
, "CaloDetDescrManager"
, "SG Key for CaloDetDescrManager in the Condition Store" }
Definition at line 85 of file FastCaloSimParamAlg.h.
◆ m_clusterize
BooleanProperty FastCaloSimParamAlg::m_clusterize |
|
private |
◆ m_containmentEnergy
DoubleProperty FastCaloSimParamAlg::m_containmentEnergy |
|
private |
◆ m_detStore
◆ m_energyFraction
DoubleProperty FastCaloSimParamAlg::m_energyFraction |
|
private |
◆ m_evtStore
◆ m_extendedExtraObjects
DataObjIDColl AthAlgorithm::m_extendedExtraObjects |
|
privateinherited |
◆ m_inputCollectionKey
◆ m_lib_struct_files
StringArrayProperty FastCaloSimParamAlg::m_lib_struct_files |
|
private |
◆ m_maxDistance
DoubleProperty FastCaloSimParamAlg::m_maxDistance |
|
private |
◆ m_maxRadius
DoubleProperty FastCaloSimParamAlg::m_maxRadius |
|
private |
◆ m_maxRadiusFCAL
DoubleProperty FastCaloSimParamAlg::m_maxRadiusFCAL |
|
private |
◆ m_maxRadiusHEC
DoubleProperty FastCaloSimParamAlg::m_maxRadiusHEC |
|
private |
◆ m_maxRadiusLAr
DoubleProperty FastCaloSimParamAlg::m_maxRadiusLAr |
|
private |
◆ m_maxRadiusTile
DoubleProperty FastCaloSimParamAlg::m_maxRadiusTile |
|
private |
◆ m_maxTime
DoubleProperty FastCaloSimParamAlg::m_maxTime |
|
private |
◆ m_maxTimeFCAL
DoubleProperty FastCaloSimParamAlg::m_maxTimeFCAL |
|
private |
◆ m_maxTimeHEC
DoubleProperty FastCaloSimParamAlg::m_maxTimeHEC |
|
private |
◆ m_maxTimeLAr
DoubleProperty FastCaloSimParamAlg::m_maxTimeLAr |
|
private |
◆ m_maxTimeTile
DoubleProperty FastCaloSimParamAlg::m_maxTimeTile |
|
private |
◆ m_minEnergy
DoubleProperty FastCaloSimParamAlg::m_minEnergy |
|
private |
◆ m_outputCollectionKey
◆ m_truncate
DoubleProperty FastCaloSimParamAlg::m_truncate |
|
private |
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
JetConstituentVector::iterator iterator
StringArrayProperty m_lib_struct_files
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
SG::ReadHandleKey< ISF_FCS_Parametrization::FCS_StepInfoCollection > m_inputCollectionKey
const CaloDetDescrElement * get_element(const Identifier &cellId) const
get element by its identifier
DoubleProperty m_minEnergy
property, see LArG4GenShowerLib::LArG4GenShowerLib
DoubleProperty m_energyFraction
property, see LArG4GenShowerLib::LArG4GenShowerLib
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
DoubleProperty m_maxRadiusLAr
property, see LArG4GenShowerLib::LArG4GenShowerLib
DoubleProperty m_maxRadiusFCAL
property, see LArG4GenShowerLib::LArG4GenShowerLib
#define ATH_MSG_VERBOSE(x)
SG::WriteHandleKey< ISF_FCS_Parametrization::FCS_StepInfoCollection > m_outputCollectionKey
void stable_sort(std::reverse_iterator< DataModel_detail::iterator< DVL > > beg, std::reverse_iterator< DataModel_detail::iterator< DVL > > end, Compare comp)
Specialization of stable_sort for DataVector/List.
SG::ReadCondHandleKey< CaloDetDescrManager > m_caloMgrKey
virtual void setOwner(IDataHandleHolder *o)=0
DoubleProperty m_containmentEnergy
property, see LArG4GenShowerLib::LArG4GenShowerLib
DoubleProperty m_maxRadiusHEC
property, see LArG4GenShowerLib::LArG4GenShowerLib
DoubleProperty m_maxTimeHEC
virtual StatusCode sysInitialize() override
Override sysInitialize.
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
StatusCode clusterize(ISF_FCS_Parametrization::FCS_StepInfoCollection *stepinfo) const
(Non-const) Iterator class for DataVector/DataList.
DoubleProperty m_maxTimeLAr
std::vector< HWIdentifier >::iterator it1
::StatusCode StatusCode
StatusCode definition for legacy code.
DoubleProperty m_maxTimeTile
StatusCode truncate(ISF_FCS_Parametrization::FCS_StepInfoCollection *stepinfo) const
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
DoubleProperty m_maxDistance
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
StatusCode initialize(bool used=true)
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
DoubleProperty m_truncate
DataObjIDColl m_extendedExtraObjects
This class provides the client interface for accessing the detector description information common to...
CaloCell_ID::CaloSample getSampling() const
cell sampling
#define ATH_MSG_WARNING(x)
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
AthAlgorithm()
Default constructor:
DoubleProperty m_maxTimeFCAL
iterator erase(iterator position)
Remove element at a given position.
BooleanProperty m_clusterize
DoubleProperty m_maxRadiusTile
property, see LArG4GenShowerLib::LArG4GenShowerLib
size_type size() const noexcept
Returns the number of elements in the collection.
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
DoubleProperty m_maxRadius
property, see LArG4GenShowerLib::LArG4GenShowerLib
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.