Skip to content
Snippets Groups Projects
Commit 3cf89b9b authored by Savannah Rose Shively's avatar Savannah Rose Shively
Browse files

initial draft

parent 5e7f84a0
No related branches found
No related tags found
No related merge requests found
Pipeline #2984699 failed
......@@ -9,7 +9,7 @@ atlas_subdir( TrackerEfficiencyExample )
atlas_add_component( TrackerEfficiencyExample
src/*.cxx src/*.h
src/components/*.cxx
LINK_LIBRARIES AthenaBaseComps xAODFaserWaveform ScintRawEvent
LINK_LIBRARIES AthenaBaseComps xAODFaserWaveform WaveRawEvent
GaudiKernel
AthViews StoreGateLib SGtests )
......
......@@ -15,6 +15,7 @@
#include <TBranch.h>
//static const std::string moduleFailureReason{"TrackerEfficiencyAlg: Exceeds max clusters"};
// Constructor with parameters:
......@@ -24,12 +25,16 @@ TrackerEfficiencyAlg::TrackerEfficiencyAlg(const std::string& name, ISvcLocator*
m_idHelper{nullptr},
m_histSvc ( "THistSvc/THistSvc", name ){}
//TrackerEfficiencyAlg::~TrackerEfficiencyAlg(){}
// Initialize method:
StatusCode TrackerEfficiencyAlg::initialize() {
ATH_MSG_INFO("TrackerEfficiencyAlg::initialize()");
ATH_CHECK( m_CaloWaveformContainer.initialize() );
// Tree
m_tree = new TTree("residTree","Cosmics residuals");
m_tree = new TTree("TrackerTree","PH_Varname");
//hist test
m_hist = new TH1D("Stations", "Stations hit", 4, 0, 3);
......@@ -40,7 +45,10 @@ StatusCode TrackerEfficiencyAlg::initialize() {
StatusCode TrackerEfficiencyAlg::execute(const EventContext& ctx) const
{
// Done
SG::ReadHandle<RawWaveformContainer> caloHandle(m_CaloWaveformContainer, ctx);
ATH_MSG_INFO("Found ReadHandle for CaloWaveforms");
ATH_MSG_INFO(*caloHandle);
return StatusCode::SUCCESS;
}
......
......@@ -29,16 +29,17 @@
#include <math.h>
#include <TProfile.h>
//Waveform
#include "xAODFaserWaveform/WaveformHitContainer.h"
#include "WaveRawEvent/RawWaveformContainer.h"
class FaserSCT_ID;
class ISvcLocator;
class StatusCode;
class TH1;
class TTree;
namespace Trk
{
class TrackStateOnSurface;
}
class TrackerEfficiencyAlg : public AthReentrantAlgorithm, AthHistogramming
{
......@@ -46,26 +47,23 @@ class TrackerEfficiencyAlg : public AthReentrantAlgorithm, AthHistogramming
/// Constructor with parameters:
TrackerEfficiencyAlg(const std::string& name, ISvcLocator* pSvcLocator);
virtual ~TrackerEfficiencyAlg(){};
/** @name Usual algorithm methods */
//@{
///Retrieve the tools used and initialize variables
virtual StatusCode initialize() override;
///Form clusters and record them in StoreGate (detector store)
virtual StatusCode execute(const EventContext& ctx) const override;
///Clean up and release the collection containers
virtual StatusCode finalize() override;
//Make this algorithm clonable.
virtual bool isClonable() const override { return true; }
//@}
const ServiceHandle<ITHistSvc>& histSvc() const;
private:
/** @name Disallow default instantiation, copy, assignment */
//@{
TrackerEfficiencyAlg() = delete;
TrackerEfficiencyAlg(const TrackerEfficiencyAlg&) = delete;
TrackerEfficiencyAlg &operator=(const TrackerEfficiencyAlg&) = delete;
//@}
SG::ReadHandleKey<RawWaveformContainer> m_CaloWaveformContainer
{ this, "CaloWaveformContainerKey", "CaloWaveforms", "ReadHandleKey for CaloWaveforms Container"};
//SG::ReadHandleKey<Waveform> m_WaveformHitContainer
//{ this, "CaloWaveformContainerKey", "CaloWaveforms", "ReadHandleKey for CaloWaveforms Container"};
const FaserSCT_ID* m_idHelper;
ServiceHandle<ITHistSvc> m_histSvc;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment