Skip to Content.
Sympa Menu

opal - Re: [Opal] Python: Return particle charges from H5-file [nosign]

opal AT

Subject: The OPAL Discussion Forum

List archive

Re: [Opal] Python: Return particle charges from H5-file [nosign]

Chronological Thread  
  • From: "Snuverink Jochem (PSI)" <jochem.snuverink AT>
  • To: "opal AT" <opal AT>, "Dr. Simon Friederich" <s.friederich AT>
  • Subject: Re: [Opal] Python: Return particle charges from H5-file [nosign]
  • Date: Mon, 22 Feb 2021 16:34:14 +0000
  • Accept-language: en-US, de-CH
  • Authentication-results: localhost; iprev=pass ( smtp.remote-ip=; spf=pass; dmarc=skipped

Dear Simon,

Yes, that should be possible with pyOPALTools if the H5-file contains the charge information which, from what I can see in the code, it should have.

Can you share a minimal example of how you created the H5 file with OPAL? What OPAL version do you use?

Best regards,


From: opal-request AT <opal-request AT> on behalf of Dr. Simon Friederich <s.friederich AT>
Sent: Monday, February 22, 2021 12:59:19 PM
To: opal AT
Subject: [Opal] Python: Return particle charges from H5-file

Dear OPAL-Team,

Is it possible to return the particle charges from an H5-file using python?

Unfortunately, the parser dataset does not contain the information whereby

mon = load_dataset(".", fname="tmp.h5")
>> ['bunchNumber', 'id', 'px', 'py', 'pz', 'time', 'turn', 'x', 'y', 'z']



consistently does not work.

Best regards

Dr. Simon Friederich
Helmholtz-Institut Mainz | Insitut für Kernphysik
Kollaboration ACID       | B
Johannes Gutenberg-Universität Mainz
Staudingerweg 18         | Johann-Joachim-Becherweg 45
55128 Mainz, Deutschland

Tel.: +49 (0)6131 39-23160
E-Mail: s.friederich AT

Archive powered by MHonArc 2.6.19.

Top of Page