diff --git a/examples/cfchannel/run_cfchannel.py b/examples/cfchannel/run_cfchannel.py index c4009ae87..d0e1c389a 100755 --- a/examples/cfchannel/run_cfchannel.py +++ b/examples/cfchannel/run_cfchannel.py @@ -42,7 +42,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice sim.lattice.extend( diff --git a/examples/cfchannel/run_cfchannel_10nC.py b/examples/cfchannel/run_cfchannel_10nC.py index 49dfaf568..759152b00 100755 --- a/examples/cfchannel/run_cfchannel_10nC.py +++ b/examples/cfchannel/run_cfchannel_10nC.py @@ -46,7 +46,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice nslice = 50 # use 1e5 for increased precision diff --git a/examples/chicane/run_chicane.py b/examples/chicane/run_chicane.py index e2f9a1f16..a4bc255b5 100644 --- a/examples/chicane/run_chicane.py +++ b/examples/chicane/run_chicane.py @@ -45,7 +45,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice ns = 25 # number of slices per ds in the element diff --git a/examples/expanding_beam/run_expanding.py b/examples/expanding_beam/run_expanding.py index 0031f75f9..0bc479ef1 100755 --- a/examples/expanding_beam/run_expanding.py +++ b/examples/expanding_beam/run_expanding.py @@ -49,7 +49,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice sim.lattice.extend([monitor, elements.Drift(ds=6.0, nslice=40), monitor]) diff --git a/examples/fodo/run_fodo.py b/examples/fodo/run_fodo.py index fbe0b3daf..2241429dc 100755 --- a/examples/fodo/run_fodo.py +++ b/examples/fodo/run_fodo.py @@ -45,7 +45,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice) ns = 25 # number of slices per ds in the element diff --git a/examples/fodo/run_fodo_programmable.py b/examples/fodo/run_fodo_programmable.py index a79e959d5..1e1edf0e5 100755 --- a/examples/fodo/run_fodo_programmable.py +++ b/examples/fodo/run_fodo_programmable.py @@ -151,7 +151,7 @@ def my_ref_drift(pge, refpart): pge2.threadsafe = True # allow OpenMP threading for speed # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice fodo = [ diff --git a/examples/fodo_rf/run_fodo_rf.py b/examples/fodo_rf/run_fodo_rf.py index ec779dda4..bac33e0ba 100644 --- a/examples/fodo_rf/run_fodo_rf.py +++ b/examples/fodo_rf/run_fodo_rf.py @@ -43,7 +43,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice sim.lattice.append(monitor) diff --git a/examples/iota_lattice/run_iotalattice.py b/examples/iota_lattice/run_iotalattice.py index 12e7366e3..a6d674e90 100644 --- a/examples/iota_lattice/run_iotalattice.py +++ b/examples/iota_lattice/run_iotalattice.py @@ -41,7 +41,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # init accelerator lattice ns = 10 # number of slices per ds in the element diff --git a/examples/kurth/run_kurth_10nC_periodic.py b/examples/kurth/run_kurth_10nC_periodic.py index dcc4f8aa3..40e8a21a4 100755 --- a/examples/kurth/run_kurth_10nC_periodic.py +++ b/examples/kurth/run_kurth_10nC_periodic.py @@ -46,7 +46,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice nslice = 20 # use 30 for increased precision diff --git a/examples/kurth/run_kurth_periodic.py b/examples/kurth/run_kurth_periodic.py index e61917849..320205dd3 100755 --- a/examples/kurth/run_kurth_periodic.py +++ b/examples/kurth/run_kurth_periodic.py @@ -43,7 +43,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice constf1 = elements.ConstF(ds=2.0, kx=0.7, ky=0.7, kt=0.7) diff --git a/examples/multipole/run_multipole.py b/examples/multipole/run_multipole.py index cdaa2dc19..7eade9ff7 100644 --- a/examples/multipole/run_multipole.py +++ b/examples/multipole/run_multipole.py @@ -42,7 +42,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice multipole = [ diff --git a/examples/quadrupole_softedge/run_quadrupole_softedge.py b/examples/quadrupole_softedge/run_quadrupole_softedge.py index fd5e9c6d4..923d5c9db 100755 --- a/examples/quadrupole_softedge/run_quadrupole_softedge.py +++ b/examples/quadrupole_softedge/run_quadrupole_softedge.py @@ -45,7 +45,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice ns = 1 # number of slices per ds in the element diff --git a/examples/rfcavity/run_rfcavity.py b/examples/rfcavity/run_rfcavity.py index 7e5c62ba1..2790f0438 100755 --- a/examples/rfcavity/run_rfcavity.py +++ b/examples/rfcavity/run_rfcavity.py @@ -115,7 +115,7 @@ ) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") sim.lattice.extend( [ diff --git a/examples/solenoid/run_solenoid.py b/examples/solenoid/run_solenoid.py index 53f11a9f1..2b2036d44 100755 --- a/examples/solenoid/run_solenoid.py +++ b/examples/solenoid/run_solenoid.py @@ -43,7 +43,7 @@ sim.add_particles(bunch_charge_C, distr, npart) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") # design the accelerator lattice sim.lattice.extend( diff --git a/examples/solenoid_softedge/run_solenoid_softedge.py b/examples/solenoid_softedge/run_solenoid_softedge.py index 05c6312d6..2cd44ca9f 100755 --- a/examples/solenoid_softedge/run_solenoid_softedge.py +++ b/examples/solenoid_softedge/run_solenoid_softedge.py @@ -125,7 +125,7 @@ ) # add beam diagnostics -monitor = elements.BeamMonitor("monitor", "h5") +monitor = elements.BeamMonitor("monitor", backend="h5") sim.lattice.extend( [ diff --git a/src/python/impactx/madx_to_impactx.py b/src/python/impactx/madx_to_impactx.py index abe2f83b1..4e8993ab4 100644 --- a/src/python/impactx/madx_to_impactx.py +++ b/src/python/impactx/madx_to_impactx.py @@ -73,7 +73,7 @@ def lattice(parsed_beamline, nslice=1): elif d["type"] == "monitor": if d["l"] > 0: impactx_beamline.append(elements.Drift(ds=d["l"], nslice=nslice)) - impactx_beamline.append(elements.BeamMonitor("monitor", "h5")) + impactx_beamline.append(elements.BeamMonitor("monitor", backend="h5")) else: raise NotImplementedError( "The beamline element named ",