diff --git a/benchmarks/clustering/scripts/cluster_plots.py b/benchmarks/clustering/scripts/cluster_plots.py index 0b99c63774d1da0292924a822e580c9f1b80dc36..c7b2fd46ef21773b584a560e15d5a3580cfb47b0 100644 --- a/benchmarks/clustering/scripts/cluster_plots.py +++ b/benchmarks/clustering/scripts/cluster_plots.py @@ -62,7 +62,7 @@ def thrown_particles_figure(rdf, save, mcbranch="MCParticles"): get_pname = np.vectorize(lambda pid: pdgbase.GetParticle(int(pid)).GetName()) # enumerate particle names - dft.loc[:, 'pname'] = get_pname(dft['pdgID'].values) + dft.loc[:, 'pname'] = get_pname(dft['PDG'].values) penum = {pname: i for i, pname in enumerate(dft['pname'].unique())} dft.loc[:, 'pname_id'] = dft['pname'].map(penum) diff --git a/benchmarks/imaging_shower_ML/scripts/check_edep_dists.py b/benchmarks/imaging_shower_ML/scripts/check_edep_dists.py index f191942ac567ea25fcc22b91b2e5a959d70c4516..76dca74439d1ee1086bf3dc6dd4a94a8f27a9b1d 100644 --- a/benchmarks/imaging_shower_ML/scripts/check_edep_dists.py +++ b/benchmarks/imaging_shower_ML/scripts/check_edep_dists.py @@ -111,12 +111,12 @@ if __name__ == '__main__': hist_vals, hist_cols = [], [] pdgbase = ROOT.TDatabasePDG() - for pdgid in dfm['pdgID'].unique(): + for pdgid in dfm['PDG'].unique(): particle = pdgbase.GetParticle(int(pdgid)) if not particle: print("Unknown pdgcode {}, they are ignored".format(int(pdgid))) continue - events_indices = dfm[dfm.loc[:, 'pdgID'] == pdgid].index.unique() + events_indices = dfm[dfm.loc[:, 'PDG'] == pdgid].index.unique() print("{} entries of particle {}".format(len(events_indices), particle.GetName())) dfe_part = dfe.loc[dfe['event'].isin(events_indices)] diff --git a/benchmarks/tracking/scripts/tracking_performance.py b/benchmarks/tracking/scripts/tracking_performance.py index ca908b3baa1f48cec0f4047f45e8b8ba6ccdb244..c39c97171e57ba22f4b32a81ee1a4095c987e0c3 100644 --- a/benchmarks/tracking/scripts/tracking_performance.py +++ b/benchmarks/tracking/scripts/tracking_performance.py @@ -62,8 +62,8 @@ def thrown_particles_figure(rdf, save, mcbranch="MCParticles"): get_pcharge = np.vectorize(lambda pid: pdgbase.GetParticle(int(pid)).Charge()/3.) # enumerate particle names - dft.loc[:, 'pname'] = get_pname(dft['pdgID'].values) - dft.loc[:, 'charge'] = get_pcharge(dft['pdgID'].values) + dft.loc[:, 'pname'] = get_pname(dft['PDG'].values) + dft.loc[:, 'charge'] = get_pcharge(dft['PDG'].values) penum = {pname: i for i, pname in enumerate(dft['pname'].unique())} dft.loc[:, 'pname_id'] = dft['pname'].map(penum)