Fork me on GitHub

Opened 5 years ago

#1420 new How to

Doing jet->Constituents.At() returns NULL pointer

Reported by: flywire Owned by:
Priority: minor Milestone:
Component: Delphes code Version: Delphes 3
Keywords: Cc:

Description

Dear Delphes,
I am trying to look at the constituents included inside Jets from the Delphes ROOT file as what you guys showed on Example3.C. But when I do

for(j = 0; j < jet->Constituents.GetEntriesFast(); ++j)
      {
        cout << "The constituent's UID is: " << jet->Constituents.GetUID(j) << endl;
        object = jet->Constituents.At(j);
        //do something else
      }

I can see that the UID of constituents can be printed out successfully but all objects are just 0 (NULL pointer), so I am not able to get any constituents information at all except its UID.

The Delphes card we used to generate the ROOT file is:
https://github.com/delphes/delphes/blob/master/cards/CMS_PhaseII/CMS_PhaseII_0PU_v02.tcl

Could you please help us solve that problem?

Thanks in advance.

Attachments (1)

JetParticles.C (2.9 KB ) - added by flywire 5 years ago.
The macro I used to get constituents in Jets

Download all attachments as: .zip

Change History (1)

by flywire, 5 years ago

Attachment: JetParticles.C added

The macro I used to get constituents in Jets

Note: See TracTickets for help on using tickets.