The matcher module calls the function "matchObjectCollection" [1] to perform the match between two objects in the eta-phi space (in hh colliders) or theta-phi space (in ee colliders). This is heavily dependent on the behaviour of the deltaR2 [2] function.
deltaR2 can either receive two particles or directly their eta-phi (theta-phi) values. When two particles are passed, the function checks what kind of collider is being used and automatically calls eta() (hh) or theta() (ee) based on that.
This leads to an inconsistency with what later happens in the Matcher module, in [3] deltaR is called by explicitly passing theta and phi, which is correct for ee colliders, but not for hh colliders, thus returning the value in the wrong space, even though the match is performed in right variables.
This can be easily solved by directly passing the particles instead of their properties and then leaving the decision to the deltaR2 function.
The matcher module calls the function "matchObjectCollection" [1] to perform the match between two objects in the eta-phi space (in hh colliders) or theta-phi space (in ee colliders). This is heavily dependent on the behaviour of the deltaR2 [2] function. deltaR2 can either receive two particles or directly their eta-phi (theta-phi) values. When two particles are passed, the function checks what kind of collider is being used and automatically calls eta() (hh) or theta() (ee) based on that. This leads to an inconsistency with what later happens in the Matcher module, in [3] deltaR is called by explicitly passing theta and phi, which is correct for ee colliders, but not for hh colliders, thus returning the value in the wrong space, even though the match is performed in right variables. This can be easily solved by directly passing the particles instead of their properties and then leaving the decision to the deltaR2 function.
[1] : https://github.com/HEP-FCC/heppy/blob/master/analyzers/Matcher.py#L105 [2] : https://github.com/HEP-FCC/heppy/blob/master/utils/deltar.py#L11 [3] : https://github.com/HEP-FCC/heppy/blob/master/analyzers/Matcher.py#L117