# specify which fields are going to be deleted
    removeIds=["sublayer"],
    # new bitfield (readout), with new segmentation
    newReadoutName=hcalEndcapReadoutName,
    debugPrint=10,
    OutputLevel=INFO)
# clusters are needed, with deposit position and cellID in bits
rewriteHCalEC.inhits.Path = "HCalEndcapCells"
rewriteHCalEC.outhits.Path = "newHCalEndcapCells"

# add noise, create all existing cells in detector
from Configurables import NoiseCaloCellsFromFileTool, TubeLayerPhiEtaCaloTool, LayerPhiEtaCaloTool, CreateCaloCells
noiseBarrel = NoiseCaloCellsFromFileTool(
    "NoiseBarrel",
    readoutName=ecalBarrelReadoutName,
    noiseFileName=ecalBarrelNoisePath,
    elecNoiseHistoName=ecalBarrelNoiseHistName,
    activeFieldName="layer",
    addPileup=False,
    numRadialLayers=8)
barrelGeometry = TubeLayerPhiEtaCaloTool("EcalBarrelGeo",
                                         readoutName=ecalBarrelReadoutName,
                                         activeVolumeName="LAr_sensitive",
                                         activeFieldName="layer",
                                         fieldNames=["system"],
                                         fieldValues=[5],
                                         activeVolumesNumber=8)
createEcalBarrelCells = CreateCaloCells(
    "CreateECalBarrelCells",
    geometryTool=barrelGeometry,
    doCellCalibration=False,  # already calibrated
    addCellNoise=True,
                   # how many cells to merge
                   # merge first 19 into new cell (id=0), next 71 into second cell (id=1), ...
                   merge = ecalNumberOfLayersToMerge,
                   OutputLevel = INFO)
mergelayers.inhits.Path = "ECalHits"
mergelayers.outhits.Path = "mergedECalHits"

#Configure tools for calo cell positions                    
from Configurables import CellPositionsDummyTool
dummyCells = CellPositionsDummyTool("CellPositions",
                                         OutputLevel = INFO)
#Configure tools for calo reconstruction
from Configurables import CalibrateCaloHitsTool, NoiseCaloCellsFromFileTool, TubeLayerPhiEtaCaloTool
calibcells = CalibrateCaloHitsTool("CalibrateCaloHitsTool", invSamplingFraction="5.4")
noise = NoiseCaloCellsFromFileTool("NoiseCaloCellsFromFileTool",
                                   cellPositionsTool=dummyCells,
    noiseFileName="root://eospublic.cern.ch//eos/experiment/fcc/hh/testsamples/fcc_ecalCellNoise_mu1000_3radialLayers_v1.root")

ecalgeo = TubeLayerPhiEtaCaloTool("EcalGeo",
                                  readoutName = ecalReadoutName,
                                  activeVolumeName = ecalVolumeName,
                                  activeFieldName = ecalIdentifierName,
                                  fieldNames = ecalFieldNames,
                                  fieldValues = ecalFieldValues,
                                  # to make it working with MergeLayers algorithm
                                  activeVolumesNumber = ecalNumberOfLayers,
                                  )

from Configurables import CreateCaloCells
createcells = CreateCaloCells("CreateCaloCells",
                              geometryTool = ecalgeo,
Esempio n. 3
0
                   # how many cells to merge
                   # merge first 19 into new cell (id=0), next 71 into second cell (id=1), ...
                   merge = ecalNumberOfLayersToMerge,
                   OutputLevel = INFO)
mergelayers.inhits.Path = "ECalHits"
mergelayers.outhits.Path = "mergedECalHits"

#Configure tools for calo cell positions                    
from Configurables import CellPositionsDummyTool
dummyCells = CellPositionsDummyTool("CellPositions",
                                         OutputLevel = INFO)
#Configure tools for calo reconstruction
from Configurables import CalibrateCaloHitsTool, NoiseCaloCellsFromFileTool, TubeLayerPhiEtaCaloTool
calibcells = CalibrateCaloHitsTool("CalibrateCaloHitsTool", invSamplingFraction="5.4")
noise = NoiseCaloCellsFromFileTool("NoiseCaloCellsFromFileTool",
                                   cellPositionsTool=dummyCells,
    noiseFileName="http://fccsw.web.cern.ch/fccsw/testsamples/fcc_ecalCellNoise_mu1000_3radialLayers_v1.root")

ecalgeo = TubeLayerPhiEtaCaloTool("EcalGeo",
                                  readoutName = ecalReadoutName,
                                  activeVolumeName = ecalVolumeName,
                                  activeFieldName = ecalIdentifierName,
                                  fieldNames = ecalFieldNames,
                                  fieldValues = ecalFieldValues,
                                  # to make it working with MergeLayers algorithm
                                  activeVolumesNumber = ecalNumberOfLayers,
                                  )

from Configurables import CreateCaloCells
createcells = CreateCaloCells("CreateCaloCells",
                              geometryTool = ecalgeo,
Esempio n. 4
0
    identifier=ecalIdentifierName,
    volumeName=ecalVolumeName,
    # how many cells to merge
    # merge first 19 into new cell (id=0), next 71 into second cell (id=1), ...
    merge=ecalNumberOfLayersToMerge,
    OutputLevel=INFO)
mergelayers.inhits.Path = "ECalHits"
mergelayers.outhits.Path = "mergedECalHits"

#Configure tools for calo reconstruction
from Configurables import CalibrateCaloHitsTool, NoiseCaloCellsFromFileTool, TubeLayerPhiEtaCaloTool
calibcells = CalibrateCaloHitsTool("CalibrateCaloHitsTool",
                                   invSamplingFraction="5.4")
noise = NoiseCaloCellsFromFileTool(
    "NoiseCaloCellsFromFileTool",
    noiseFileName=
    "/eos/project/f/fccsw-web/testsamples/fcc_ecalCellNoise_mu1000_3radialLayers_v1.root"
)

ecalgeo = TubeLayerPhiEtaCaloTool(
    "EcalGeo",
    readoutName=ecalReadoutName,
    activeVolumeName=ecalVolumeName,
    activeFieldName=ecalIdentifierName,
    fieldNames=ecalFieldNames,
    fieldValues=ecalFieldValues,
    # to make it working with MergeLayers algorithm
    activeVolumesNumber=ecalNumberOfLayers,
    OutputLevel=DEBUG)

from Configurables import CreateCaloCells
## clusters are needed, with deposit position and cellID in bits
#rewriteHCal.inhits.Path = "HCalBarrelCells"
#rewriteHCal.outhits.Path = "HCalBarrelCellsStep1"
#
#createHcalCells = CreateCaloCells("CreateHCalCells",
#                                  doCellCalibration=False,
#                                  addCellNoise=False, filterCellNoise=False,
#                                  hits="HCalBarrelCellsStep1",
#                                  cells="newHCalBarrelCells")

from Configurables import NoiseCaloCellsFromFileTool, TubeLayerPhiEtaCaloTool, CalibrateCaloHitsTool, NoiseCaloCellsFlatTool, LayerPhiEtaCaloTool
#ECal Barrel noise
noiseBarrel = NoiseCaloCellsFromFileTool("NoiseBarrel",
                                         readoutName = ecalBarrelReadoutName,
                                         noiseFileName = ecalBarrelNoisePath,
                                         elecNoiseHistoName = ecalBarrelNoiseHistName,
                                         cellPositionsTool = ECalBcells,
                                         activeFieldName = "layer",
                                         addPileup = False,
                                         numRadialLayers = 8)

#add noise, create all existing cells in detector
barrelGeometry = TubeLayerPhiEtaCaloTool("EcalBarrelGeo",
                                         readoutName = ecalBarrelReadoutName,
                                         activeVolumeName = "LAr_sensitive",
                                         activeFieldName = "layer",
                                         fieldNames = ["system"],
                                         fieldValues = [5],
                                         activeVolumesNumber = 8)

createEcalBarrelCells = CreateCaloCells("CreateECalBarrelCellsNoise",
                                        geometryTool = barrelGeometry,
# old bitfield (readout)
rewriteHCalEC.oldReadoutName = "HECPhiEta"
# specify which fields are going to be deleted
rewriteHCalEC.removeIds = ["sublayer"]
# new bitfield (readout), with new segmentation
rewriteHCalEC.newReadoutName = hcalEndcapReadoutName
rewriteHCalEC.debugPrint = 10
rewriteHCalEC.OutputLevel = INFO
# clusters are needed, with deposit position and cellID in bits
rewriteHCalEC.inhits.Path = "HCalEndcapCells"
rewriteHCalEC.outhits.Path = "newHCalEndcapCells"
ApplicationMgr().TopAlg += [rewriteHCalEC]

# add noise, create all existing cells in detector
from Configurables import NoiseCaloCellsFromFileTool
noiseBarrel = NoiseCaloCellsFromFileTool("NoiseBarrel")
noiseBarrel.readoutName = ecalBarrelReadoutName
noiseBarrel.noiseFileName = "root://eospublic.cern.ch//eos/experiment/fcc/hh/testsamples/elecNoise_ecalBarrel_50Ohm_traces2_2shieldWidth.root"
noiseBarrel.elecNoiseHistoName = "h_elecNoise_fcc_"
noiseBarrel.activeFieldName = "layer"
noiseBarrel.addPileup = False
noiseBarrel.cellPositionsTool = ECalBcells
noiseBarrel.numRadialLayers = 8

from Configurables import TubeLayerPhiEtaCaloTool
barrelGeometry = TubeLayerPhiEtaCaloTool("EcalBarrelGeo")
barrelGeometry.readoutName = ecalBarrelReadoutName
barrelGeometry.activeVolumeName = "LAr_sensitive"
barrelGeometry.activeFieldName = "layer"
barrelGeometry.fieldNames = ["system"]
barrelGeometry.fieldValues = [5]
Esempio n. 7
0
    readout=ecalReadoutName,
    # cells in which field should be merged
    identifier=ecalIdentifierName,
    volumeName=ecalVolumeName,
    # how many cells to merge
    # merge first 19 into new cell (id=0), next 71 into second cell (id=1), ...
    merge=ecalNumberOfLayersToMerge,
    OutputLevel=INFO)
mergelayers.DataInputs.inhits.Path = "ECalHits"
mergelayers.DataOutputs.outhits.Path = "mergedECalHits"

#Configure tools for calo reconstruction
from Configurables import CalibrateCaloHitsTool, NoiseCaloCellsFromFileTool, TubeLayerPhiEtaCaloTool
calibcells = CalibrateCaloHitsTool("CalibrateCaloHitsTool",
                                   invSamplingFraction="5.4")
noise = NoiseCaloCellsFromFileTool("NoiseCaloCellsFromFileTool")
ecalgeo = TubeLayerPhiEtaCaloTool(
    "EcalGeo",
    readoutName=ecalReadoutName,
    activeVolumeName=ecalVolumeName,
    activeFieldName=ecalIdentifierName,
    fieldNames=ecalFieldNames,
    fieldValues=ecalFieldValues,
    # to make it working with MergeLayers algorithm
    activeVolumesNumber=ecalNumberOfLayers,
    OutputLevel=DEBUG)

from Configurables import CreateCaloCells
createcells = CreateCaloCells("CreateCaloCells",
                              geometryTool=ecalgeo,
                              doCellCalibration=True,
Esempio n. 8
0
readNeighboursMap = TopoCaloNeighbours("ReadNeighboursMap",
                                       fileName = "/afs/cern.ch/work/c/cneubuse/public/FCChh/neighbours_map_segHcal.root",
                                       OutputLevel = DEBUG)

##############################################################################################################
#######                          NOISE/NO NOISE TOOL FOR CLUSTER THRESHOLDS                      #############
##############################################################################################################

if elNoise:

    from Configurables import CreateCaloCells, NoiseCaloCellsFromFileTool, TubeLayerPhiEtaCaloTool, CalibrateCaloHitsTool, NoiseCaloCellsFlatTool, NestedVolumesCaloTool
    # ECal Barrel noise
    noiseBarrel = NoiseCaloCellsFromFileTool("NoiseBarrel",
                                             readoutName = ecalBarrelReadoutName,
                                             noiseFileName = ecalBarrelNoisePath,
                                             elecNoiseHistoName = ecalBarrelNoiseHistName,
                                             activeFieldName = "layer",
                                             addPileup = False,
                                             numRadialLayers = 8)

    # add noise, create all existing cells in detector
    barrelGeometry = TubeLayerPhiEtaCaloTool("EcalBarrelGeo",
                                             readoutName = ecalBarrelReadoutName,
                                             activeVolumeName = "LAr_sensitive",
                                             activeFieldName = "layer",
                                             fieldNames = ["system"],
                                             fieldValues = [5],
                                             activeVolumesNumber = 8)

    createEcalBarrelCells = CreateCaloCells("CreateECalBarrelCells",
                                            geometryTool = barrelGeometry,