68 produces< std::vector<sim::SimEnergyDeposit> >();
75 fNtEdepAna = tfs->
make<TNtuple>(
"nt_edep_ana",
"Edep PosDiff Ana Ntuple",
"energy:orig_x:orig_y:orig_z:orig_el:orig_ph:shift_x:shift_y:shift_z:shift_el:shift_ph");
80 lar::providerFrom<detinfo::DetectorPropertiesService>(),
82 lar::providerFrom<spacecharge::SpaceChargeService>());
88 auto sce = lar::providerFrom<spacecharge::SpaceChargeService>();
90 std::unique_ptr< std::vector<sim::SimEnergyDeposit> >
91 outEdepVecPtr(
new std::vector<sim::SimEnergyDeposit>() );
92 auto & outEdepVec(*outEdepVecPtr);
96 auto const& inEdepVec(*inEdepHandle);
98 outEdepVec.reserve(inEdepVec.size());
102 for(
auto const&
edep : inEdepVec){
103 if(sce->EnableSimSpatialSCE()){
104 posOffsetsStart = sce->GetPosOffsets({
edep.StartX(),
edep.StartY(),
edep.StartZ()});
105 posOffsetsEnd = sce->GetPosOffsets({
edep.EndX(),
edep.EndY(),
edep.EndZ()});
113 (
float)(
edep.StartY()+posOffsetsStart.Y()),
114 (
float)(
edep.StartZ()+posOffsetsStart.Z())},
116 (
float)(
edep.EndY()+posOffsetsEnd.Y()),
117 (
float)(
edep.EndZ()+posOffsetsEnd.Z())},
125 outEdepVec.back().X(),outEdepVec.back().Y(),outEdepVec.back().Z(),
126 outEdepVec.back().NumElectrons(),outEdepVec.back().NumPhotons());
129 e.
put(std::move(outEdepVecPtr));
Store parameters for running LArG4.
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double >, ROOT::Math::GlobalCoordinateSystemTag > Vector_t
Type for representation of momenta in 3D space.
void produce(art::Event &e) override
ShiftEdepSCE(fhicl::ParameterSet const &p)
ShiftEdepSCE & operator=(ShiftEdepSCE const &)=delete
ProductID put(std::unique_ptr< PROD > &&product)
double NumberIonizationElectrons() const
#define DEFINE_ART_MODULE(klass)
ROOT::Math::PositionVector3D< ROOT::Math::Cartesian3D< Length_t > > Point_t
void CalculateIonizationAndScintillation(sim::SimEnergyDeposit const &edep)
double NumberScintillationPhotons() const
T * make(ARGS...args) const
bool getByLabel(std::string const &label, std::string const &productInstanceName, Handle< PROD > &result) const
larg4::ISCalculationSeparate fISAlg
contains information for a single step in the detector simulation
void Initialize(const detinfo::LArProperties *larp, const detinfo::DetectorProperties *detp, const sim::LArG4Parameters *lgp, const spacecharge::SpaceCharge *sce)