Skip to content

[FASTSIM] Adapt CALO to the fast simulation interface

Michal Mazurek requested to merge mimazure_fastsim into FASTSIM

@gcorti @kreps @adavis

needs Gaussino/Gaussino!20 (merged)

Gauss Fast Simulation Interface

This adapts the CALO code to the fast simulation interface in Gaussino/Gaussino!20 (merged).

Fast Simulation Models

  • Immediate Deposit Model (for testing)

Subdetectors

  • Calorimeters in mass geometry
  • Calorimeters in parallel geometry

Calorimetry in mass geometry

Basic setup for ECAL:

# general setup for an ImmediateDeposit model for fast simulation
from Gaussino.Simulation import SimPhase
SimPhase().FastSimulationCreator = "ImmediateDepositCreator"
from Configurables import FastSimulationCreator
fastsim = FastSimulationCreator('ImmediateDepositCreator')

fastsim.Model = {
    'EcalImmediateDeposit': {
        'Type': 'ImmediateDepositModel',
        "OutputLevel": DEBUG,
    }
}

fastsim.Region = {
    'EcalImmediateDeposit': {
        'SensitiveDetectorName': 'Ecal',
        "OutputLevel": DEBUG,
    }
}

fastsim.Physics = {
    'ParticlePIDs': [22],
    "OutputLevel": DEBUG,
}

Mass geometry for calorimeters is tricky due to complex geometry and non-uniform calo hits collection (CaloHit, CaloSubHit and MCCaloHit). There is a possibility to turn off this postprocessing by:

# Bypass postprecessing in ECAL sensitive detector when creating
# a fast-generated MCCaloHit
from Configurables import EcalSensDet
ecalsdet = EcalSensDet("GaussGeo.Ecal")
ecalsdet.OutputLevel = -10
# bypass Birk's & Non-Uniformity
ecalsdet.BypassCaloCorrections = True
# bypass time binning
# (will create only one hit /cell/particle/25ns)
ecalsdet.BypassCaloTiming = True
# having both true means basically G4FastHit = MCCaloHit

Test ecal_mass_geo_immediate_deposit.qmt

Scans ECAL with 64 * 52 photons so that space between each deposit is exactly the length of the outer cell 121.7 * mm. ImmediateDeposit fast simulation model is used so that all the photon's energy is immediately deposited in the first cell met when passing through the fast simulation envelope. The material of all logical volumes, but the sensitive detector is set to vacuum in order to ensure that gammas will not interact before reaching the envelope. Finally, BypassCaloCorrections = True and BypassCaloTiming = True so that in the end each G4FastSimHit = MCCaloHit.

It is expected to always get 10 events * 10 MeV * (64 * 52 - 24 (beam hole)) = 330.4 GeV

image

Red lines connect the last od endVertices of each MCParticle with the center of the MCaloHit.

Edited by Michal Mazurek

Merge request reports