[Rivet] [Rivet-svn] rivet: 4mom shouldnt be pointers cos they get reordered behind t...

Andy Buckley andy.buckley at cern.ch
Fri Mar 2 16:03:37 GMT 2018


This is a bit odd, because after application the projection should be a const reference -- not something that can be reordered. Unless we're using mutable internally... which is possible, but I thought we called the sorting earlier. If it's possible for particle-list elements to be re-ordered after project(), breaking references/pointers exposed to user code, then we definitely need to fix that. Is that what was happening here, Jon?

Andy
Dr Andy Buckley, Lecturer / Royal Society University Research Fellow
Particle Physics Experiment Group, University of Glasgow

On Mar 1 2018, at 6:34 pm, David Grellscheid <david.grellscheid at durham.ac.uk> wrote:
>
> Hi Jon,
> Great find! Thanks! We've been looking at the return values of the finders before, and this clearly demonstrates that they have very delicate semantics right now with ordering.
> We'll need to look at this properly, it's not the job of the analysis authors to get this right.
>
> See you,
> David
>
>
> On 1 March 2018 18:15:01 GMT, Rivet Mercurial <rivet at projects.hepforge.org> wrote:
> > details: https://rivet.hepforge.org/hg/rivet/rev/ce40a6dcf214
> > branches: release-2-6-x
> > changeset: 6246:ce40a6dcf214
> > user: Jon Butterworth <j.butterworth at cern.ch>
> > date: Wed Feb 28 23:10:34 2018 +0100
> > description:
> > 4mom shouldnt be pointers cos they get reordered behind the scenes and
> > mT is then always zero.
> >
> > diffs (20 lines):
> > --- a/analyses/pluginCMS/CMS_2016_I1491953.cc Tue Feb 27 22:34:33 2018
> > +0000
> > +++ b/analyses/pluginCMS/CMS_2016_I1491953.cc Wed Feb 28 23:10:34 2018
> > +0100
> > @@ -107,9 +107,14 @@
> > const WFinder& wfinder_mu = applyProjection<WFinder>(event,
> > "WFinder_mu");
> > if (wfinder_mu.bosons().size() != 1) vetoEvent;
> >
> > - const FourMomentum& lepton0 =
> > wfinder_mu.constituentLeptons()[0].momentum();
> > - const FourMomentum& neutrino =
> > wfinder_mu.constituentNeutrinos()[0].momentum();
> > - double WmT = sqrt( 2 * lepton0.pT() * neutrino.pT() * (1 -
> > cos(deltaPhi(lepton0, neutrino))) );
> > + //const FourMomentum& lepton0 =
> > wfinder_mu.constituentLeptons()[0].momentum();
> > + //const FourMomentum& neutrino =
> > wfinder_mu.constituentNeutrinos()[0].momentum();
> > + //double WmT = sqrt( 2 * lepton0.pT() * neutrino.pT() * (1 -
> > cos(deltaPhi(lepton0, neutrino))) );
> > +
> > + const FourMomentum lepton0 =
> > wfinder_mu.constituentLepton().momentum();
> > + const FourMomentum neutrino =
> > wfinder_mu.constituentNeutrino().momentum();
> > + double WmT = wfinder_mu.mT();
> > +
> > if (WmT < 50.0*GeV) vetoEvent;
> > if (lepton0.abseta() > 2.1 || lepton0.pT() < 25.0*GeV) vetoEvent;
> >
> > _______________________________________________
> > Rivet-svn mailing list
> > Rivet-svn at projects.hepforge.org
> > https://www.hepforge.org/lists/listinfo/rivet-svn
>
> _______________________________________________
> Rivet mailing list
> Rivet at projects.hepforge.org
> https://www.hepforge.org/lists/listinfo/rivet
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.hepforge.org/lists-archive/rivet/attachments/20180302/eee72066/attachment.html>


More information about the Rivet mailing list