Commit 165063a6 authored by Walter Lampl's avatar Walter Lampl
Browse files

Merge branch 'CleanUp_LayerHough' into 'master'

MuonLayerHough - Code cleaning

See merge request atlas/athena!47523
parents c9748e9a 620dfabe
......@@ -16,15 +16,15 @@
class MuonCombinePatternTool : public AthAlgTool, virtual public Muon::IMuonCombinePatternTool {
private:
struct ChamberInfo {
ChamberInfo() : neta(0), nphi(0), ninside(0), noutside(0), ninsidePat(0), noutsidePat(0), phiMin(1e9), phiMax(-1e9) {}
int neta;
int nphi;
int ninside;
int noutside;
int ninsidePat;
int noutsidePat;
double phiMin;
double phiMax;
ChamberInfo() = default;
int neta{0};
int nphi{0};
int ninside{0};
int noutside{0};
int ninsidePat{0};
int noutsidePat{0};
double phiMin{FLT_MAX};
double phiMax{-FLT_MAX};
};
typedef std::map<Identifier, ChamberInfo> IdChMap;
typedef IdChMap::iterator IdChIt;
......@@ -106,7 +106,7 @@ private:
/** calculate new track parameters of match (only for cosmics!) returns [r0,
* phi, rz0, theta]*/
double* updateParametersForCosmics(const Muon::MuonPrdPattern* phipattern, const Muon::MuonPrdPattern* etapattern) const;
std::array<double,4> updateParametersForCosmics(const Muon::MuonPrdPattern* phipattern, const Muon::MuonPrdPattern* etapattern) const;
/** calculate phi and r0 for cosmic patterns, phi estimate needs to be given
*/
......@@ -119,7 +119,7 @@ private:
/** update patterns based on new track parameters (used only for cosmics)
* builds 2 new prd patterns */
static std::pair<const Muon::MuonPrdPattern*, const Muon::MuonPrdPattern*> updatePatternsForCosmics(
const Muon::MuonPrdPattern* phipattern, const Muon::MuonPrdPattern* etapattern, const double* new_pars);
const Muon::MuonPrdPattern* phipattern, const Muon::MuonPrdPattern* etapattern, const std::array<double,4>& new_pars);
/** calculates global position of prd */
static const Amg::Vector3D& globalPrdPos(const Trk::PrepRawData* prd);
......@@ -129,7 +129,7 @@ private:
void addCandidate(
const Muon::MuonPrdPattern* etapattern, const Muon::MuonPrdPattern* phipattern,
std::vector<std::pair<const Muon::MuonPrdPattern*, const Muon::MuonPrdPattern*>>& candidates, bool add_asspattern,
std::vector<const Muon::MuonPrdPattern*>& patternsToDelete,
std::vector<std::unique_ptr<const Muon::MuonPrdPattern>>& patternsToDelete,
const std::map<const Trk::PrepRawData*, std::set<const Trk::PrepRawData*, Muon::IdentifierPrdLess>>* phiEtaHitAssMap) const;
/** clean candidates from subsets or duplicates */
......
......@@ -15,7 +15,7 @@ atlas_add_library( MuonHoughPatternToolsLib
INCLUDE_DIRS ${ROOT_INCLUDE_DIRS}
PRIVATE_INCLUDE_DIRS
LINK_LIBRARIES ${ROOT_LIBRARIES} AthenaBaseComps GeoPrimitives GaudiKernel MuonDetDescrUtils MuonHoughPatternEvent MuonPattern MuonPrepRawData MuonSegment MuonRecToolInterfaces MuonLayerHough TrkDriftCircleMath MuonIdHelpersLib MuonClusterizationLib MuonRecHelperToolsLib StoreGateLib
PRIVATE_LINK_LIBRARIES AtlasHepMCLib CxxUtils EventPrimitives xAODMuon xAODTruth MuonReadoutGeometry MuonRIO_OnTrack TrkSurfaces TrkTruthData )
PRIVATE_LINK_LIBRARIES AtlasHepMCLib CxxUtils EventPrimitives xAODMuon xAODTruth MuonReadoutGeometry MuonRIO_OnTrack TrkSurfaces TrkTruthData FourMomUtils)
atlas_add_component( MuonHoughPatternTools
src/components/*.cxx
......
/*
Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
*/
#ifndef MUONHOUGHPATTERNALGS_MUONHOUGHPATTERNFINDERTOOL_H
#define MUONHOUGHPATTERNALGS_MUONHOUGHPATTERNFINDERTOOL_H
#include <TFile.h>
#include <TH1.h>
#include <iostream>
#include <string>
#include <vector>
......@@ -12,19 +15,16 @@
#include "AthenaBaseComps/AthAlgTool.h"
#include "GaudiKernel/ServiceHandle.h"
#include "GaudiKernel/ToolHandle.h"
#include "MuonHoughPatternTools/IMuonHoughPatternTool.h"
#include "MuonIdHelpers/IMuonIdHelperSvc.h"
#include "MuonPattern/MuonPatternCollection.h"
#include "MuonPattern/MuonPatternCombinationCollection.h"
#include "MuonRecHelperTools/MuonEDMPrinterTool.h"
#include "MuonRecToolInterfaces/IMuonCombinePatternTool.h"
#include "MuonRecToolInterfaces/IMuonHoughPatternFinderTool.h"
#include "MuonRecToolInterfaces/IMuonHoughPatternTool.h"
#include "MuonSegment/MuonSegmentCombinationCollection.h"
#include "TrkDriftCircleMath/DriftCircle.h"
class TH1F;
class TFile;
class MuonHoughHitContainer;
namespace Muon {
......@@ -35,7 +35,7 @@ namespace Muon {
MuonHoughPatternFinderTool(const std::string&, const std::string&, const IInterface*);
/** destructor */
virtual ~MuonHoughPatternFinderTool() = default;
virtual ~MuonHoughPatternFinderTool();
/** initialize */
virtual StatusCode initialize();
......@@ -47,19 +47,23 @@ namespace Muon {
std::pair<std::unique_ptr<MuonPatternCombinationCollection>, std::unique_ptr<Muon::HoughDataPerSectorVec>> find(
const std::vector<const MdtPrepDataCollection*>& mdtCols, const std::vector<const CscPrepDataCollection*>& cscCols,
const std::vector<const TgcPrepDataCollection*>& tgcCols, const std::vector<const RpcPrepDataCollection*>& rpcCols,
const MuonSegmentCombinationCollection* cscSegmentCombis, const EventContext& ctx) const;
const MuonSegmentCombinationCollection* cscSegmentCombis, const EventContext& ctx) const override;
std::pair<std::unique_ptr<MuonPatternCombinationCollection>, std::unique_ptr<HoughDataPerSectorVec>> find(
const MdtPrepDataContainer* mdtCont, const CscPrepDataContainer* cscCols, const TgcPrepDataContainer* tgcCont,
const RpcPrepDataContainer* rpcCont, const sTgcPrepDataContainer* stgcCont, const MMPrepDataContainer* mmCont,
const EventContext& ctx) const override;
private:
template <class T> std::vector<const T*> stdVec(const MuonPrepDataContainer<T>* cont) const;
/** retrieves all hits and converts them into internal EDM */
const MuonHoughHitContainer* getAllHits(
std::unique_ptr<MuonHoughHitContainer> getAllHits(
const std::vector<const MdtPrepDataCollection*>& mdtCols, const std::vector<const CscPrepDataCollection*>& cscCols,
const std::vector<const TgcPrepDataCollection*>& tgcCols, const std::vector<const RpcPrepDataCollection*>& rpcCols,
const MuonSegmentCombinationCollection* cscSegmentCombis, std::map<int, std::vector<std::pair<int, int>>>& rpcmdtstationmap,
std::map<int, std::vector<std::pair<int, int>>>& tgcmdtstationmap,
std::map<const Trk::PrepRawData*, std::set<const Trk::PrepRawData*, Muon::IdentifierPrdLess>>* phietahitassociation) const;
/** possibility to skip events, nothing implemented */
static bool cut();
std::map<const Trk::PrepRawData*, std::set<const Trk::PrepRawData*, Muon::IdentifierPrdLess>>& phietahitassociation) const;
/** analyse hits */
MuonPatternCombinationCollection* analyse(
......@@ -70,28 +74,27 @@ namespace Muon {
private:
/** record patterncollection to storegate or deletes collection when
* m_recordAllOutput is false */
void record(MuonPrdPatternCollection* patCol, const SG::WriteHandleKey<MuonPrdPatternCollection>& key,
void record(std::unique_ptr<MuonPrdPatternCollection>& patCol, const SG::WriteHandleKey<MuonPrdPatternCollection>& key,
const EventContext& ctx) const;
/** convert and add rpc preprawdata collection (1 chamber) */
void addRpcCollection(
Muon::RpcPrepDataCollection::const_iterator cit_begin, Muon::RpcPrepDataCollection::const_iterator cit_end,
MuonHoughHitContainer* hitcontainer, std::map<int, std::vector<std::pair<int, int>>>& rpcmdtstationmap,
std::map<const Trk::PrepRawData*, std::set<const Trk::PrepRawData*, Muon::IdentifierPrdLess>>* phietahitassociation) const;
const RpcPrepDataCollection* rpc_coll, MuonHoughHitContainer& hitcontainer,
std::map<int, std::vector<std::pair<int, int>>>& rpcmdtstationmap,
std::map<const Trk::PrepRawData*, std::set<const Trk::PrepRawData*, Muon::IdentifierPrdLess>>& phietahitassociation) const;
/** convert and add mdt preprawdata collection (1 chamber) */
void addMdtCollection(Muon::MdtPrepDataCollection::const_iterator cit_begin, Muon::MdtPrepDataCollection::const_iterator cit_end,
MuonHoughHitContainer* hitcontainer, std::map<int, std::vector<std::pair<int, int>>>& rpcmdtstationmap,
void addMdtCollection(const MdtPrepDataCollection* mdt_coll, MuonHoughHitContainer& hitcontainer,
std::map<int, std::vector<std::pair<int, int>>>& rpcmdtstationmap,
std::map<int, std::vector<std::pair<int, int>>>& tgcmdtstationmap) const;
/** convert and add csc preprawdata collection (1 chamber) */
void addCscCollection(
Muon::CscPrepDataCollection::const_iterator cit_begin, Muon::CscPrepDataCollection::const_iterator cit_end,
MuonHoughHitContainer* hitcontainer,
std::map<const Trk::PrepRawData*, std::set<const Trk::PrepRawData*, Muon::IdentifierPrdLess>>* phietahitassociation) const;
const CscPrepDataCollection* csc_coll, MuonHoughHitContainer& hitcontainer,
std::map<const Trk::PrepRawData*, std::set<const Trk::PrepRawData*, Muon::IdentifierPrdLess>>& phietahitassociation) const;
/** convert and add tgc preprawdata collection (1 chamber) */
void addTgcCollection(
Muon::TgcPrepDataCollection::const_iterator cit_begin, Muon::TgcPrepDataCollection::const_iterator cit_end,
MuonHoughHitContainer* hitcontainer, std::map<int, std::vector<std::pair<int, int>>>& tgcmdtstationmap,
std::map<const Trk::PrepRawData*, std::set<const Trk::PrepRawData*, Muon::IdentifierPrdLess>>* phietahitassociation) const;
const Muon::TgcPrepDataCollection*, MuonHoughHitContainer& hitcontainer,
std::map<int, std::vector<std::pair<int, int>>>& tgcmdtstationmap,
std::map<const Trk::PrepRawData*, std::set<const Trk::PrepRawData*, Muon::IdentifierPrdLess>>& phietahitassociation) const;
/** finds best segment for given driftcircle vector (nl1/2 = number of dc's in
* ml 1 and 2, angledif is difference between angle of segment and
......@@ -172,18 +175,18 @@ namespace Muon {
/** histogram file for studies on weighting (only in use, when m_use_histos is
* true) */
TFile* m_file{};
std::unique_ptr<TFile> m_file{};
/** all hits histograms for studies on weighting (only in use, when
* m_use_histos is true) */
TH1F* m_weighthistogram{};
std::unique_ptr<TH1> m_weighthistogram{};
/** mdt histogram */
TH1F* m_weighthistogrammdt{};
std::unique_ptr<TH1> m_weighthistogrammdt{};
/** rpc histogram */
TH1F* m_weighthistogramrpc{};
std::unique_ptr<TH1> m_weighthistogramrpc{};
/** tgc histogram */
TH1F* m_weighthistogramtgc{};
std::unique_ptr<TH1> m_weighthistogramtgc{};
/** csc histogram */
TH1F* m_weighthistogramcsc{};
std::unique_ptr<TH1> m_weighthistogramcsc{};
SG::WriteHandleKey<MuonPrdPatternCollection> m_CosmicPhiPatternsKey{this, "CosmicPhiKey", "CosmicPhiPatterns"};
SG::WriteHandleKey<MuonPrdPatternCollection> m_CosmicEtaPatternsKey{this, "CosmicEtaPatterns", "CosmicEtaPatterns"};
......
......@@ -5,14 +5,15 @@
#ifndef MUONHOUGHPATTERNTOOLS_MUONHOUGHPATTERNTOOL_H
#define MUONHOUGHPATTERNTOOLS_MUONHOUGHPATTERNTOOL_H
#include <TFile.h>
#include <TH2.h>
#include "AthenaBaseComps/AthAlgTool.h"
#include "MuonHoughPatternEvent/MuonHoughMathUtils.h"
#include "MuonHoughPatternTools/IMuonHoughPatternTool.h"
#include "MuonRecToolInterfaces/IMuonHoughPatternTool.h"
class MuonHoughTransformSteering;
class MuonHoughTransformer;
class TFile;
class TH2F;
class MuonHoughPatternTool : virtual public IMuonHoughPatternTool, public AthAlgTool {
public:
......@@ -22,34 +23,32 @@ public:
virtual ~MuonHoughPatternTool() = default;
/** method that builds the patterns */
virtual void makePatterns(const MuonHoughHitContainer* hitcontainer, MuonHoughPatternContainerShip& houghpatterns) const;
virtual void makePatterns(const MuonHoughHitContainer& hitcontainer, MuonHoughPatternContainerShip& houghpatterns) const override;
/** initiates private members */
virtual StatusCode initialize();
virtual StatusCode initialize() override;
/** deletes private members */
virtual StatusCode finalize();
virtual StatusCode finalize() override;
/** returns phipattern container in EDM */
virtual MuonPrdPatternCollection* getPhiMuonPatterns(MuonHoughPatternContainerShip& houghpatterns) const;
virtual std::unique_ptr<MuonPrdPatternCollection> getPhiMuonPatterns(MuonHoughPatternContainerShip& houghpatterns) const override;
/** returns etapattern container in EDM */
virtual MuonPrdPatternCollection* getEtaMuonPatterns(MuonHoughPatternContainerShip& houghpatterns) const;
virtual std::unique_ptr<MuonPrdPatternCollection> getEtaMuonPatterns(MuonHoughPatternContainerShip& houghpatterns) const override;
/** resets houpattern vector, called once per event from FinderTool*/
void reset(MuonHoughPatternContainerShip& houghpattern) const;
/** creates houghpatterns, called from FinderTool */
MuonHoughPatternContainerShip emptyHoughPattern() const;
private:
/** method that builds the patterns */
virtual void makePatterns(int id_number, double weightmdt, const MuonHoughHitContainer* event,
MuonHoughPatternContainerShip& houghpatterns) const;
void makePatterns(int id_number, double weightmdt, const MuonHoughHitContainer& event,
MuonHoughPatternContainerShip& houghpatterns) const;
/** returns curvedpattern container in EDM */
MuonPrdPatternCollection* getCurvedMuonPatterns(MuonHoughPatternContainerShip& houghpatterns) const;
std::unique_ptr<MuonPrdPatternCollection> getCurvedMuonPatterns(MuonHoughPatternContainerShip& houghpatterns) const;
/** reset association flag of hits in m_event */
static void resetAssociation(const MuonHoughHitContainer* event);
static void resetAssociation(const MuonHoughHitContainer& event);
/** reduces Detector sizes for Hough Histograms to find patterns from muons from the Interaction Point (default on) */
void useIPMuons();
......@@ -70,41 +69,38 @@ private:
* @param[in] event_to_analyse The hitcontainer which will be associated to the pattern
* @param[in] houghtransform The HoughTransform
*/
bool analyseHisto(int id_number, int level, const MuonHoughHitContainer* event_to_analyse, MuonHoughTransformSteering* houghtransform,
MuonHoughPatternContainerShip& houghpatterns) const;
/** method to analyse the pattern build, currently nothing implemented */
void analyseTrack(int id_number, const MuonHoughHitContainer* event_to_analyse, MuonHoughTransformSteering* houghtransform) const;
bool analyseHisto(int id_number, int level, const std::unique_ptr<MuonHoughHitContainer>& event_to_analyse,
std::unique_ptr<MuonHoughTransformSteering>& houghtransform, MuonHoughPatternContainerShip& houghpatterns) const;
/** returns if there are hits left */
static bool hitsLeft(const MuonHoughHitContainer* event);
static bool hitsLeft(const MuonHoughHitContainer& event);
/** returns number of hits left (unused) */
int numberOfHits(const MuonHoughHitContainer* event) const;
int numberOfHits(const MuonHoughHitContainer& event) const;
/** checks if hit is already in one of the found houghpatterns (unused) */
bool hitInHoughPattern(MuonHoughHit* hit, const MuonHoughPatternContainer& houghpattern) const;
/** returns a hitcontainer with hits not yet used in pattern */
static MuonHoughHitContainer* hitsNotInPattern(const MuonHoughHitContainer* event, int id_number);
static std::unique_ptr<MuonHoughHitContainer> hitsNotInPattern(const MuonHoughHitContainer& event, int id_number);
/** rescales hits per iteration to reduce number of patterns when already some have been found */
void weightRescaling(const MuonHoughHitContainer* event, int id_number, int level) const;
void weightRescaling(const MuonHoughHitContainer& event, int id_number, int level) const;
/** calculates new weights based on rejection factor (1-origweight) and number of hits in event, only done for MDTs */
void calculateWeights(const MuonHoughHitContainer* event, double weightmdt) const;
void calculateWeights(const MuonHoughHitContainer& event, double weightmdt) const;
/** returns number of hits that are in both hough patterns */
int overlapHoughPatterns(const MuonHoughPattern* houghpattern1, const MuonHoughPattern* houghpattern2) const;
int overlapHoughPatterns(const MuonHoughPattern& houghpattern1, const MuonHoughPattern& houghpattern2) const;
/** selects the hitcontainer to be used for filling the histograms */
MuonHoughHitContainer* whichEventHough(int id, const MuonHoughHitContainer* event, double weightmdt) const;
std::unique_ptr<MuonHoughHitContainer> whichEventHough(int id, const MuonHoughHitContainer& event, double weightmdt) const;
/** selects the hitcontainer to be used to associate to the maxima */
MuonHoughHitContainer* whichEventAssociation(int id, const MuonHoughHitContainer* event) const;
std::unique_ptr<MuonHoughHitContainer> whichEventAssociation(int id, const MuonHoughHitContainer& event) const;
/** returns the Houghtransform for the id */
MuonHoughTransformSteering* whichHoughTransform(int id) const;
std::unique_ptr<MuonHoughTransformSteering> whichHoughTransform(int id) const;
/** returns the maximum iteration, not in use */
std::vector<int> maxLevelHoughPattern(const MuonHoughPatternContainerShip& houghpattern) const;
......@@ -117,15 +113,17 @@ private:
void transformCoordsMaximum(std::pair<double, double>& coordsmaximum, double r0_true) const;
/** converts hough pattern to EDM eta patterns */
Muon::MuonPrdPattern* houghPatternToEtaPattern(MuonHoughPattern* houghpattern) const;
std::unique_ptr<Muon::MuonPrdPattern> houghPatternToEtaPattern(const MuonHoughPattern& houghpattern) const;
/** converts hough pattern to EDM phi patterns */
Muon::MuonPrdPattern* houghPatternToPhiPattern(MuonHoughPattern* houghpattern) const;
std::unique_ptr<Muon::MuonPrdPattern> houghPatternToPhiPattern(const MuonHoughPattern& houghpattern) const;
/** converts and combines two hough patterns to one EDM phi pattern */
Muon::MuonPrdPattern* houghPatternsToOneEtaPattern(MuonHoughPattern* houghpattern1, MuonHoughPattern* houghpattern2) const;
std::unique_ptr<Muon::MuonPrdPattern> houghPatternsToOneEtaPattern(const MuonHoughPattern& houghpattern1,
const MuonHoughPattern& houghpattern2) const;
/** converts and combines two hough patterns to one EDM phi pattern */
Muon::MuonPrdPattern* houghPatternsToOnePhiPattern(MuonHoughPattern* houghpattern1, MuonHoughPattern* houghpattern2) const;
std::unique_ptr<Muon::MuonPrdPattern> houghPatternsToOnePhiPattern(const MuonHoughPattern& houghpattern1,
const MuonHoughPattern& houghpattern2) const;
/** converts hough pattern to EDM phi patterns and cleans it from outliers */
Muon::MuonPrdPattern* houghPatternToCleanPhiPattern(MuonHoughPattern* houghpattern) const;
std::unique_ptr<Muon::MuonPrdPattern> houghPatternToCleanPhiPattern(MuonHoughPattern& houghpattern) const;
/** returns minimum number of hits a hough pattern can contain */
unsigned int getThresholdHoughPattern(int id_number) const;
......@@ -133,13 +131,13 @@ private:
double getThresholdHisto(int id_number) const;
/** calculates the mdt weight cut value */
void setWeightMdtCutValue(const MuonHoughHitContainer* event, double& weightmdt) const;
void setWeightMdtCutValue(const MuonHoughHitContainer& event, double& weightmdt) const;
/** hit through weight cut? */
bool hitThroughCut(MuonHoughHit* hit, double weightmdt) const;
/** pointer to the file name for the hough histograms */
TFile* m_file{};
std::unique_ptr<TFile> m_file;
/** object for use of mathematical formulas for trackmodels */
MuonHoughMathUtils m_muonhoughmathutils;
......@@ -157,7 +155,7 @@ private:
Gaudi::Property<bool> m_use_curvedhough{this, "UseCurvedHough", true};
/** number of hough transforms currently supported (7) */
int m_number_of_ids;
int m_number_of_ids{7};
/** number of iterations (5) */
Gaudi::Property<int> m_number_of_maxima{this, "NumberOfMaximaPerIterations", 5};
......@@ -165,9 +163,9 @@ private:
/** use rpc phi strips in phi-patterns (true) */
// const bool m_use_rpc_measures_phi;
/** use rpc eta strips in eta-patterns (true) */
const bool m_use_rpc_measures_eta;
static constexpr bool m_use_rpc_measures_eta{true};
/** use interaction point constraint (true) */
bool m_use_ip;
bool m_use_ip{false};
/** minimal size for a phi pattern (1) */
Gaudi::Property<unsigned int> m_thresholdpattern_xyz{this, "SetThresholdPatternRPhi", 1};
......@@ -177,85 +175,82 @@ private:
// hittosegment association:
/** distance hits are associated with pattern in mm */
const double m_maximum_residu_mm;
static constexpr double m_maximum_residu_mm{500.};
/** distance hits are associated with pattern in mm for cosmics */
const double m_maximum_residu_mm_cosmics;
static constexpr double m_maximum_residu_mm_cosmics{2000.};
/** distance hits are associated with pattern in degrees */
const double m_maximum_residu_angle;
static constexpr double m_maximum_residu_angle{3.};
/** // number of maximum iterations over houghtransform */
const int m_maximum_level;
static constexpr int m_maximum_level{5};
// for hough_correction:
/** use hough correction
* to correct the maximum found in rz-plane slightly as there is a bias in the houghtransform
*/
// const bool m_use_hough_correction;
/** constant 1 for z for hough correction */
const double m_z_cor_constant;
static constexpr double m_z_cor_constant{-10000.};
/** constant 2 for z for hough correction */
const double m_z_cor_constant2;
static constexpr double m_z_cor_constant2{6000.};
/** constant 1 for theta for hough correction */
const double m_theta_cor_constant;
static constexpr double m_theta_cor_constant{-0.042};
/** constant 2 for theta for hough correction */
const double m_theta_cor_constant2;
static constexpr double m_theta_cor_constant2{4000.};
// detectorsizes:
/** acceptancy of patterns in xy (phi) in mm */
double m_detectorsize_xy;
double m_detectorsize_xy{0.};
/** acceptancy of patterns in yz (not used) in mm */
double m_detectorsize_yz;
double m_detectorsize_yz{0.};
/** acceptancy of patterns in rz (eta) in mm */
double m_detectorsize_rz;
double m_detectorsize_rz{0.};
/** size of full detector in xy (phi) in mm, used as acceptancy for cosmics */
const double m_detectorsize_xy_full;
static constexpr double m_detectorsize_xy_full{15000.};
/** size of full detector in yz (not used) in mm, used as acceptancy for cosmics */
const double m_detectorsize_yz_full;
static constexpr double m_detectorsize_yz_full{25000.};
/** size of full detector in rz (eta) in mm, used as acceptancy for cosmics */
const double m_detectorsize_rz_full;
static constexpr double m_detectorsize_rz_full{27750.};
/** acceptancy of patterns for ip in xy (phi) in mm */
const double m_detectorsize_xy_ip;
static constexpr double m_detectorsize_xy_ip{600.};
/** acceptancy of patterns for ip in yz (not used) in mm */
const double m_detectorsize_yz_ip;
static constexpr double m_detectorsize_yz_ip{1000.};
/** acceptancy of patterns for ip in rz (eta) in mm */
const double m_detectorsize_rz_ip;
static constexpr double m_detectorsize_rz_ip{1500.};
/** max range of angle in xyz in degrees (360) */
const double m_detectorsize_angle_xyz;
static constexpr double m_detectorsize_angle_xyz{360.};
/** max range of angle in rz in degrees (180) */
const double m_detectorsize_angle_rz;
static constexpr double m_detectorsize_angle_rz{180.};
/** max range of 1/sqrt(curvature) for curved transform, corresponds to 0.02 ~ 2,5m ~ 1.6GeV */
// const double m_detectorsize_inv_sqrt_curvature;
// properties of histograms:
/** bin width for xy */
const double m_stepsize_xy;
static constexpr double m_stepsize_xy{75.};
/** bin width for yz */
const double m_stepsize_yz;
static constexpr double m_stepsize_yz{250.};
/** bin width for rz */
const double m_stepsize_rz;
static constexpr double m_stepsize_rz{75.};
/** bin width for xy cosmics */
const double m_stepsize_xy_cosmics;
static constexpr double m_stepsize_xy_cosmics{150.};
/** bin width for rzcosmics */
const double m_stepsize_rz_cosmics;
static constexpr double m_stepsize_rz_cosmics{150.};
/** bin width for angle in xyz */
const double m_stepsize_per_angle_xyz;
static constexpr double m_stepsize_per_angle_xyz{0.25};
/** bin width for angle in rz */
const double m_stepsize_per_angle_rz;
static constexpr double m_stepsize_per_angle_rz{0.25};
/** bin width for angle in xy cosmics */
const double m_stepsize_per_angle_xy_cosmics;
static constexpr double m_stepsize_per_angle_xy_cosmics{1.};
/** bin width for angle in rzcosmics */
const double m_stepsize_per_angle_rz_cosmics;
static constexpr double m_stepsize_per_angle_rz_cosmics{2.};
/** bin width for 1/sqrt(curvature) */
// const double m_stepsize_per_inv_sqrt_curvature;
/** new curved properties */
const int m_nbins_curved;
static constexpr int m_nbins_curved{160};
/** weight_cut for hits in hough */
Gaudi::Property<bool> m_weightcut{this, "ApplyWeightCut", true};
......@@ -277,7 +272,7 @@ private:
/** number of sectors (different regions in which patterns can be found in the same iteration) in rz */
Gaudi::Property<int> m_number_of_sectors_rz{this, "SetNumberOfSectorsREta", 16};
/** number of sectors (different regions in which patterns can be found in the same iteration) in rzcosmics */
int m_number_of_sectors_rz_cosmics;
int m_number_of_sectors_rz_cosmics{12};
/** output level (range 0-10) (default 0) */
Gaudi::Property<int> m_printlevel{this, "Printlevel", 0};
......
......@@ -8,13 +8,13 @@
#include <set>
#include "AthenaBaseComps/AthAlgTool.h"
#include "FourMomUtils/xAODP4Helpers.h"
#include "GaudiKernel/ServiceHandle.h"
#include "GaudiKernel/ToolHandle.h"
#include "GeoPrimitives/GeoPrimitives.h"
#include "MuonClusterization/RpcHitClustering.h"
#include "MuonClusterization/TgcHitClustering.h"
#include "MuonDetDescrUtils/MuonSectorMapping.h"