PrChecker ghost rate

I don't know if this is the expected behaviour or not.

I made some trials on the default PrChecker output and a custom one replicating the same configuration but removing the Eta25Cut.

Basically i get different ghost rate.

I am wondering, do we really want to prompt by default the Ghost rate on Velo tracks using only the Velo tracks we found in eta 2 and 5 ( Velo tracks for which WE assign ETA ) ?

I dump here the default log i get for 10 events :

PrChecker2Fast is what is executed by default and it has 19 ghosts. MyPrChecker is what i add by hand in the sequence and i configure it as posted later ( and not vetoing electrons)

PrChecker2Fast       INFO Results
PrChecker2Fast....   INFO **** Velo                             2062 tracks including             19 ghosts [ 0.92 %], Event average  0.84 % ****
PrChecker2Fast....   INFO                          01_velo :    1019 from     1040 [ 97.98 %]     28 clones [ 2.67 %], purity: 99.83 %, hitEff: 93.62 %, hitEffFirst3: 92.84 %, hitEffLast: 93.65 %
PrChecker2Fast....   INFO                          02_long :     590 from      592 [ 99.66 %]      5 clones [ 0.84 %], purity: 99.86 %, hitEff: 97.04 %, hitEffFirst3: 95.69 %, hitEffLast: 97.73 %
PrChecker2Fast....   INFO                     03_long>5GeV :     379 from      379 [100.00 %]      1 clones [ 0.26 %], purity: 99.91 %, hitEff: 97.89 %, hitEffFirst3: 96.93 %, hitEffLast: 98.43 %
PrChecker2Fast....   INFO                  04_long_strange :      26 from       27 [ 96.30 %]      0 clones [ 0.00 %], purity: 99.04 %, hitEff: 98.42 %, hitEffFirst3: 97.44 %, hitEffLast: 99.40 %
PrChecker2Fast....   INFO             05_long_strange>5GeV :      13 from       13 [100.00 %]      0 clones [ 0.00 %], purity: 98.08 %, hitEff: 97.95 %, hitEffFirst3: 97.44 %, hitEffLast: 98.81 %
PrChecker2Fast....   INFO                    06_long_fromB :      31 from       31 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 97.20 %, hitEffFirst3: 95.70 %, hitEffLast: 98.15 %
PrChecker2Fast....   INFO               07_long_fromB>5GeV :      28 from       28 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 97.93 %, hitEffFirst3: 97.62 %, hitEffLast: 97.95 %
PrChecker2Fast....   INFO                08_long_electrons :      26 from       29 [ 89.66 %]      1 clones [ 3.70 %], purity: 97.28 %, hitEff: 91.16 %, hitEffFirst3: 86.42 %, hitEffLast: 94.57 %
PrChecker2Fast....   INFO          09_long_fromB_electrons :       1 from        1 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff:100.00 %, hitEffFirst3:100.00 %, hitEffLast:100.00 %
PrChecker2Fast....   INFO   11_long_fromB_P>3GeV_Pt>0.5GeV :      27 from       27 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 97.73 %, hitEffFirst3: 97.53 %, hitEffLast: 97.87 %
PrChecker2Fast....   INFO                              GeV :      27 from       27 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 97.73 %, hitEffFirst3: 97.53 %, hitEffLast: 97.87 %
PrChecker2Fast....   INFO
PrChecker2           INFO Results
MyPrChecker          INFO Results
MyPrChecker.Velo     INFO **** Velo                             2419 tracks including             35 ghosts [ 1.45 %], Event average  1.31 % ****
MyPrChecker.Velo     INFO writing LaTeX table to ./TexEfficienciesVeloBackwardThenForwardBestPhysics.tex_Velo.tex
MyPrChecker.Velo     INFO                             Long :     590 from      592 [ 99.66 %]      5 clones [ 0.84 %], purity: 99.86 %, hitEff: 97.04 %, hitEffFirst3: 95.69 %, hitEffLast: 97.73 %
MyPrChecker.Velo     INFO                        LongFromB :      31 from       31 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 97.20 %, hitEffFirst3: 95.70 %, hitEffLast: 98.15 %
MyPrChecker.Velo     INFO                 LongFromB_pLess5 :       3 from        3 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 90.48 %, hitEffFirst3: 77.78 %, hitEffLast:100.00 %
MyPrChecker.Velo     INFO                 LongFromB_pMore5 :      28 from       28 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 97.93 %, hitEffFirst3: 97.62 %, hitEffLast: 97.95 %
MyPrChecker.Velo     INFO              LongFromB_pTMore400 :      29 from       29 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 97.89 %, hitEffFirst3: 97.70 %, hitEffLast: 98.02 %
MyPrChecker.Velo     INFO       LongFromB_pTMore400_pMore3 :      29 from       29 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 97.89 %, hitEffFirst3: 97.70 %, hitEffLast: 98.02 %
MyPrChecker.Velo     INFO                        LongFromD :       9 from        9 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 92.73 %, hitEffFirst3: 92.59 %, hitEffLast: 88.89 %
MyPrChecker.Velo     INFO                 LongFromD_pLess5 :       5 from        5 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 89.14 %, hitEffFirst3: 93.33 %, hitEffLast: 80.00 %
MyPrChecker.Velo     INFO                 LongFromD_pMore5 :       4 from        4 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 97.22 %, hitEffFirst3: 91.67 %, hitEffLast:100.00 %
MyPrChecker.Velo     INFO              LongFromD_pTMore400 :       8 from        8 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 96.83 %, hitEffFirst3: 91.67 %, hitEffLast:100.00 %
MyPrChecker.Velo     INFO       LongFromD_pTMore400_pMore3 :       7 from        7 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 96.37 %, hitEffFirst3: 90.48 %, hitEffLast:100.00 %
MyPrChecker.Velo     INFO                        LongFromS :      26 from       27 [ 96.30 %]      0 clones [ 0.00 %], purity: 99.04 %, hitEff: 98.42 %, hitEffFirst3: 97.44 %, hitEffLast: 99.40 %
MyPrChecker.Velo     INFO                 LongFromS_pLess5 :      13 from       14 [ 92.86 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 98.90 %, hitEffFirst3: 97.44 %, hitEffLast:100.00 %
MyPrChecker.Velo     INFO                 LongFromS_pMore5 :      13 from       13 [100.00 %]      0 clones [ 0.00 %], purity: 98.08 %, hitEff: 97.95 %, hitEffFirst3: 97.44 %, hitEffLast: 98.81 %
MyPrChecker.Velo     INFO              LongFromS_pTMore400 :      13 from       13 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 97.62 %, hitEffFirst3: 94.87 %, hitEffLast:100.00 %
MyPrChecker.Velo     INFO       LongFromS_pTMore400_pMore3 :      12 from       12 [100.00 %]      0 clones [ 0.00 %], purity:100.00 %, hitEff: 97.42 %, hitEffFirst3: 94.44 %, hitEffLast:100.00 %
MyPrChecker.Velo     INFO                     VeloBackward :    1265 from     1392 [ 90.88 %]     38 clones [ 2.92 %], purity: 99.84 %, hitEff: 93.68 %, hitEffFirst3: 93.12 %, hitEffLast: 92.83 %
MyPrChecker.Velo     INFO                      VeloForward :     911 from     1008 [ 90.38 %]     12 clones [ 1.30 %], purity: 99.67 %, hitEff: 96.91 %, hitEffFirst3: 97.94 %, hitEffLast: 94.16 %
MyPrChecker.Velo     INFO                       Velo_eta25 :    1019 from     1040 [ 97.98 %]     28 clones [ 2.67 %], purity: 99.83 %, hitEff: 93.62 %, hitEffFirst3: 92.84 %, hitEffLast: 93.65 %
from Configurables import PrChecker2
    from Configurables import LoKi__Hybrid__MCTool
    MCHybridFactory = LoKi__Hybrid__MCTool("MCHybridFactory")
    MCHybridFactory.Modules = ["LoKiMC.decorators"]
    # FAST

    from Configurables import PrChecker2
    checker = PrChecker2("MyPrChecker")
    checker.GhostProbCut = 0.9
    checker.VeloTracks = "Rec/Track/Keyed/Velo"
    checker.WriteVeloHistos = -1
    #"Rec/Track/Keyed/Velo"
    #PrChecker2("PrChecker2").WriteVeloHistos = 2
    checker.Eta25Cut = False
    checker.VetoElectrons = True
    Eta25Cut = "& (MCETA>2.0) & (MCETA<5.0)"
    PMore5 = "& (MCP>5000)"
    PLess5 = "& (MCP<5000)"
    PMore3 = "& (MCP>3000)"
    PTMore400 = "& (MCPT> 400)"
    PTMore600 = "& (MCPT> 600)"
    PTMore800 = "& (MCPT> 800)"
    PTMore1000 = "& (MCPT> 1000)"
    checker.WriteTexOutput = True
    checker.TexOutputName = NAMETEST+".tex"
    checker.TexOutputFolder = "./TexEfficiencies"
    checker.MyVeloCuts = {
        "VeloForward" : "(isVelo) & (MCETA < 0.)",
        "VeloBackward" : "(isVelo) & (MCETA > 0.)",
        "Velo_eta25" : "(isVelo)" + Eta25Cut,
        "Long" : "(isLong)" + Eta25Cut ,
        "LongFromB"  : " (isLong) & fromB"+Eta25Cut,
        "LongFromD"  : " (isLong) & fromD"+Eta25Cut,
        "LongFromS"  : " (isLong) & strange"+Eta25Cut ,

        "LongFromB_pMore5"  : " (isLong) & fromB"+Eta25Cut + PMore5,
        "LongFromD_pMore5"  : " (isLong) & fromD"+Eta25Cut + PMore5,
        "LongFromS_pMore5"  : " (isLong) & strange"+Eta25Cut + PMore5 ,

        "LongFromB_pLess5"  : " (isLong) & fromB"+Eta25Cut + PLess5,
        "LongFromD_pLess5"  : " (isLong) & fromD"+Eta25Cut + PLess5,
        "LongFromS_pLess5"  : " (isLong) & strange"+Eta25Cut + PLess5 ,

        "LongFromB_pTMore400"  :  "(isLong) & fromB"+Eta25Cut + PTMore400,
        "LongFromD_pTMore400"  : " (isLong) & fromD"+Eta25Cut + PTMore400,
        "LongFromS_pTMore400"  : " (isLong) & strange"+Eta25Cut + PTMore400,

        "LongFromB_pTMore400_pMore3"  :  "(isLong) & fromB"+Eta25Cut + PTMore400 + PMore3,
        "LongFromD_pTMore400_pMore3"  : " (isLong) & fromD"+Eta25Cut + PTMore400 + PMore3,
        "LongFromS_pTMore400_pMore3"  : " (isLong) & strange"+Eta25Cut + PTMore400 + PMore3,
    }

FYI : @gligorov , @adudziak , @sstahl , @cattanem , @chasse, @decianm

Edited by Andre Gunther