Skip to content
This repository has been archived by the owner on May 9, 2024. It is now read-only.

Commit

Permalink
add python modules
Browse files Browse the repository at this point in the history
  • Loading branch information
cmantill committed Oct 12, 2020
1 parent d70b539 commit cfc55f7
Showing 1 changed file with 52 additions and 0 deletions.
52 changes: 52 additions & 0 deletions python/hcal.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
"""Configuration for Hcal pipeline"""

from LDMX.Framework import ldmxcfg

class HcalDigiProducer(ldmxcfg.Producer) :
"""Configuration for Digitization producer in the HCal
Sets all parameters to reasonable defaults.
Examples
--------
from LDMX.EventProc.hcal import HcalDigiProducer
p.sequence.append( HcalDigiProducer() )
"""

def __init__(self,name = 'hcalDigis') :
super().__init__(name,'ldmx::HcalDigiProducer','Hcal')

self.meanNoise = 0.02
self.readoutThreshold= 1
self.strips_side_lr_per_layer = 12
self.num_side_lr_hcal_layers = 26
self.strips_side_tb_per_layer = 12
self.num_side_tb_hcal_layers = 28
self.strips_back_per_layer = 60 # n strips correspond to 5 cm wide bars
self.num_back_hcal_layers = 96
self.super_strip_size = 1 # 1 = 5 cm readout, 2 = 10 cm readout, ...
self.mev_per_mip = 4.66 # measured 1.4 MeV for a 6mm thick tile, so for 20mm bar = 1.4*20/6
self.pe_per_mip = 68. # PEs per MIP at 1m (assume 80% attentuation of 1m)
self.strip_attenuation_length = 5. # this is in m
self.strip_position_resolution = 150. # this is in mm
self.sim_hit_pass_name = '' #use any pass available

class HcalVetoProcessor(ldmxcfg.Producer) :
"""Configuration for veto in HCal
Sets all parameters to reasonable defaults.
Examples
--------
from LDMX.EventProc.hcal import HcalVetoProcessor
p.sequence.append( HcalVetoProcessor() )
"""

def __init__(self,name = 'hcalVeto') :
super().__init__(name,'ldmx::HcalVetoProcessor','Hcal')

self.pe_threshold = 5.0
self.max_time = 50.0
self.max_depth = 4000.0
self.back_min_pe = 1.

0 comments on commit cfc55f7

Please sign in to comment.