Skip to Content.
Sympa Menu

opal - [Opal] Load phase space data in different time steps for a bunch in .h5 file

opal AT lists.psi.ch

Subject: The OPAL Discussion Forum

List archive

[Opal] Load phase space data in different time steps for a bunch in .h5 file


Chronological Thread  
  • From: Siao-Cing Liou <sawout AT gmail.com>
  • To: opal AT lists.psi.ch
  • Subject: [Opal] Load phase space data in different time steps for a bunch in .h5 file
  • Date: Tue, 14 Mar 2023 15:28:22 +0800
  • Authentication-results: mc4.ethz.ch; iprev=pass (mail-yb1-f181.google.com) smtp.remote-ip=209.85.219.181; spf=pass smtp.mailfrom=gmail.com; dkim=pass header.d=gmail.com header.s=20210112 header.a=rsa-sha256; dmarc=pass header.from=gmail.com

Dear All,
I am new to OPAL. I use the example code "RingCyclotron.in" with "PSDUMPFREQ = 250", "turns = 5", "nstep = 2000", and "NPART = 1e2". I want to load the phase space data (x,y,z) in different time steps for a bunch. 
I use the following code in pyOPALTools:
------------------------------------------------------------------------
from opal import load_dataset

ds = load_dataset('./', fname='RingCyclotron.h5')
x = ds.getData('x')
y = ds.getData('y')
z = ds.getData('z')
------------------------------------------------------------------------
From the above script, it (x,y,z) only comes out the initial bunch data. Is any method to load phase space data in different time steps? Or the setting is wrong?

Best regards
Siao-Cing Liou

Attachment: 20230314_opal.zip
Description: Zip archive




Archive powered by MHonArc 2.6.24.

Top of Page