示例#1
0
def getTauJetRNNEvaluator(_n,
                          NetworkFile0P="",
                          NetworkFile1P="",
                          NetworkFile3P="",
                          OutputVarname="RNNJetScore",
                          MaxTracks=10,
                          MaxClusters=6,
                          MaxClusterDR=1.0,
                          InputLayerScalar="scalar",
                          InputLayerTracks="tracks",
                          InputLayerClusters="clusters",
                          OutputLayer="rnnid_output",
                          OutputNode="sig_prob"):
    _name = sPrefix + _n
    from tauRecTools.tauRecToolsConf import TauJetRNNEvaluator
    myTauJetRNNEvaluator = TauJetRNNEvaluator(
        name=_name,
        NetworkFile0P=NetworkFile0P,
        NetworkFile1P=NetworkFile1P,
        NetworkFile3P=NetworkFile3P,
        OutputVarname=OutputVarname,
        MaxTracks=MaxTracks,
        MaxClusters=MaxClusters,
        MaxClusterDR=MaxClusterDR,
        InputLayerScalar=InputLayerScalar,
        InputLayerTracks=InputLayerTracks,
        InputLayerClusters=InputLayerClusters,
        OutputLayer=OutputLayer,
        OutputNode=OutputNode,
        IncShowerSubtr=tauFlags.useShowerSubClusters())
    cached_instances[_name] = myTauJetRNNEvaluator
    return myTauJetRNNEvaluator
示例#2
0
def getMvaTESVariableDecorator():
    _name = sPrefix + 'MvaTESVariableDecorator'
    from tauRecTools.tauRecToolsConf import MvaTESVariableDecorator
    MvaTESVariableDecorator = MvaTESVariableDecorator(
        name=_name,
        Key_vertexInputContainer=_DefaultVertexContainer,
        IncShowerSubtr=tauFlags.useShowerSubClusters())
    cached_instances[_name] = MvaTESVariableDecorator
    return MvaTESVariableDecorator
示例#3
0
def getTauIDVarCalculator():
    _name = sPrefix + 'TauIDVarCalculator'
    from tauRecTools.tauRecToolsConf import TauIDVarCalculator
    myTauIDVarCalculator = TauIDVarCalculator(
        name=_name,
        Key_vertexInputContainer=_DefaultVertexContainer,
        IncShowerSubtr=tauFlags.useShowerSubClusters())
    cached_instances[_name] = myTauIDVarCalculator
    return myTauIDVarCalculator
示例#4
0
def getPi0ClusterCreator():
    _name = sPrefix + 'Pi0ClusterCreator'

    if _name in cached_instances:
        return cached_instances[_name]

    from tauRecTools.tauRecToolsConf import TauPi0ClusterCreator
    TauPi0ClusterCreator = TauPi0ClusterCreator(
        name=_name,
        Key_Pi0ClusterContainer="TauPi0SubtractedClusters",
        IncShowerSubtr=tauFlags.useShowerSubClusters())

    cached_instances[_name] = TauPi0ClusterCreator
    return TauPi0ClusterCreator
示例#5
0
def getTauAxis():
    _name = sPrefix + 'TauAxis'

    if _name in cached_instances:
        return cached_instances[_name]

    from tauRecTools.tauRecToolsConf import TauAxisSetter
    TauAxisSetter = TauAxisSetter(
        name=_name,
        ClusterCone=0.2,
        VertexCorrection=True,
        IncShowerSubtr=tauFlags.useShowerSubClusters())

    cached_instances[_name] = TauAxisSetter
    return TauAxisSetter
示例#6
0
def getElectronVetoVars():
    _name = sPrefix + 'TauElectronVetoVars'

    if _name in cached_instances:
        return cached_instances[_name]

    from tauRecTools.tauRecToolsConf import TauElectronVetoVariables
    TauElectronVetoVariables = TauElectronVetoVariables(
        name=_name,
        VertexCorrection=True,
        ParticleCaloExtensionTool=getParticleCaloExtensionTool(),
        tauEVParticleCache=getParticleCache(),
        IncShowerSubtr=tauFlags.useShowerSubClusters())

    cached_instances[_name] = TauElectronVetoVariables
    return TauElectronVetoVariables
示例#7
0
def getTauSubstructure():
    _name = sPrefix + 'TauSubstructure'

    if _name in cached_instances:
        return cached_instances[_name]

    from tauRecTools.tauRecToolsConf import TauSubstructureVariables
    TauSubstructureVariables = TauSubstructureVariables(
        name=_name,
        # parameters for CaloIsoCorrected variable
        maxPileUpCorrection=4000.,  #MeV
        pileUpAlpha=1.0,
        VertexCorrection=True,
        IncShowerSubtr=tauFlags.useShowerSubClusters())

    cached_instances[_name] = TauSubstructureVariables
    return TauSubstructureVariables
示例#8
0
def getCellVariables(cellConeSize=0.2, prefix=''):
    #if prefix is not given, take global one
    if not prefix:
        prefix = sPrefix

    _name = prefix + 'CellVariables'

    if _name in cached_instances:
        return cached_instances[_name]

    from tauRecTools.tauRecToolsConf import TauCellVariables
    TauCellVariables = TauCellVariables(
        name=_name,
        CellEthreshold=0.2 * GeV,
        StripEthreshold=0.2 * GeV,
        CellCone=cellConeSize,
        VertexCorrection=True,
        IncShowerSubtr=tauFlags.useShowerSubClusters())

    cached_instances[_name] = TauCellVariables
    return TauCellVariables